cole-trapnell-lab / cicero-release

https://cole-trapnell-lab.github.io/cicero-release/
MIT License
56 stars 14 forks source link

Questions regarding to "plot_connections", "plot_cells" and "new_cell_data_set", thank you for your help. #35

Closed MQMQ2018 closed 4 years ago

MQMQ2018 commented 5 years ago

Dear Hannah,

Thank you for your quick response, you are very helpful. I still have 3 questions below, if possible, could you give me some tips? Thank you so much!

  1. What is the reason why "yscale" is invalid for drawing the connection plot as below in cicero for monocle3? What should I do to figure it out? Thank you so much.

    ===

    plot_connections(conns, "chr2", 13451, 9848598,gene_model = gene_anno, coaccess_cutoff = .005, connection_width = .5,collapseTranscripts = "longest" ) Error in valid.viewport(x, y, width, height, just, gp, clip, xscale, yscale, : invalid 'yscale' in viewport

    ===

  2. How can I plot cell figures based on genes assigned after processing "Cicero gene activity scores" step in cicero for monocle3? Is the way below the correct way to do it? Or any other ways? Thank you.

    ===

    plot_cells(input_cds, genes=c("GR"),show_trajectory_graph=TRUE,label_cell_groups=FALSE,label_leaves=FALSE) Error in plot_cells(input_cds, genes = c("GR"), show_trajectory_graph = TRUE, : None of the provided genes were found in the cds

    ===

  3. How can I merge 10x genomics samples as one single cell_data_set (CDS) objective with sample names as a feature stored at a column of colData(cds), through multiple loading samples by "new_cell_data_set" function?

Thank you so much!

Best, Qi

jbalberge commented 5 years ago

Hi, Regarding 1., does your gene_anno data frame contain NA transcripts? I had to remove them to get rid from the invalid 'yscale' in viewport error:

gene_anno <- subset(gene_anno, !(is.na(transcript)))

JB

MQMQ2018 commented 5 years ago

Thank you so much, Jbalberge. The first question have been figured out. Many Thanks,

Best, Qi

raivivek commented 5 years ago

@jbalberge Would you how can I generate genome wide gene model that I can use with the plot_connections function?

jbalberge commented 5 years ago

Have you looked at this section? https://cole-trapnell-lab.github.io/cicero-release/docs/#frequently-asked-questions

MQMQ2018 commented 5 years ago

@raivivek I tried to use full length of chr1, plot_connections will generate huge Robj, unless you loose the resolution that you might get the figure.

MQMQ2018 commented 5 years ago

Regarding to question2, in another word, is there anyway to do plot_cells in Cicero such as plotting by Monocle3 using "plot_cells(cds, genes=c("cpna-2", "egl-21", "ram-2", "inos-1"))"? If defining 5000Kbp upper region the end of target genebody as the detection region? Based on cicero_gene_activities table? And further is there marker chromosome accessible sites for clustering in cicero and potential targeted marker genes nearby the marker chromosome accessible sites ? Thank you so much. Best, Qi

hpliner commented 4 years ago

Sorry for the delayed response. For the 2nd question, you'll need to create a CDS object from the gene activity matrix - i.e. where the expression matrix is the gene activity matrix and the gene metadata is gene information. You can then make the CDS using new_cell_data_set and plot it as though it were RNA.

For the third question, you should be able to use the "combine_cds" function from monocle3 - however, this won't solve the issue of having different peak sets (potentially overlapping) from your separate cell ranger runs. Combining those is outside the scope of cicero and would likely require some bedtools-style merging.

I'm going to close this out, but if I've missed a question, you can reopen!