crispr_analysis_utils.guide_qc.guides_to_fastq
crispr_analysis_utils.guide_qc.guides_to_fastq
guides_to_fastq(guides_input: str | Path | DataFrame, output_path: str | Path, *, quality_char: str = 'I', pam: str = '', add_leading_g: bool = False, id_col: int | str = 0, sequence_col: int | str = 1) -> Path
Write guide sequences into a synthetic FASTQ file.
Parameters:
-
guides_input(str | Path | DataFrame) –Either: - Path to a tab-separated file - pandas DataFrame
-
output_path(str | Path) –FASTQ output path. Use
.gzsuffix for gzip-compressed output. -
quality_char(str, default:'I') –Single character repeated to sequence length for quality scores. Defaults to
I(Q = 40 in Phred+33 encoding). -
pam(str, default:'') –Optional PAM sequence appended to each guide sequence.
-
add_leading_g(bool, default:False) –If
True, prependGonly when the sequence does not already start withG. -
id_col(int | str, default:0) –Guide id column in
guides_input(integer position or column name). -
sequence_col(int | str, default:1) –Guide sequence column in
guides_input(integer position or column name).
Returns:
-
Path–Path to the written FASTQ file.
Source code in src/crispr_analysis_utils/guide_qc.py
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | |