Open olgabot opened 7 years ago
10X genomics has examples in Python and R for how to read their outputs, and we should integrate these into flotilla
flotilla
import csv import os import scipy.io genome = "hg19" matrices_dir = "/opt/sample345/outs/filtered_gene_bc_matrices" human_matrix_dir = os.path.join(matrices_dir, genome) mat = scipy.io.mmread(os.path.join(human_matrix_dir, "matrix.mtx")) genes_path = os.path.join(human_matrix_dir, "genes.tsv") gene_ids = [row[0] for row in csv.reader(open(genes_path), delimiter="\t")] gene_names = [row[1] for row in csv.reader(open(genes_path), delimiter="\t")] barcodes_path = os.path.join(human_matrix_dir, "barcodes.tsv") barcodes = [row[0] for row in csv.reader(open(barcodes_path), delimiter="\t")]
10X genomics has examples in Python and R for how to read their outputs, and we should integrate these into
flotilla