genomepy.genome.sequences.get_random_sequences

genomepy.genome.sequences.get_random_sequences(self, n=10, length=200, chroms=None, max_n=0.1, outtype='list')

Return random genomic sequences.

Parameters
  • n (int , optional) – Number of sequences to return.

  • length (int , optional) – Length of sequences to return.

  • chroms (list , optional) – Return sequences only from these chromosomes.

  • max_n (float , optional) – Maximum fraction of Ns.

  • outtype (string , optional) – return the output as list or string. Options: “list” or “string”, default: “list”.

Returns

coordinates as lists or strings: List with [chrom, start, end] genomic coordinates. String with “chrom:start-end” genomic coordinates (can be used as input for track2fasta).

Return type

list