Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How the kernel density of cell fraction was plotted in the paper? #173

Open
zh9118 opened this issue Mar 31, 2022 · 2 comments
Open

How the kernel density of cell fraction was plotted in the paper? #173

zh9118 opened this issue Mar 31, 2022 · 2 comments

Comments

@zh9118
Copy link

zh9118 commented Mar 31, 2022

Hi,

Trying to get some help from here.

I am trying to make the kernel density plot which was shown in the paper. However, didn't find such a function in the package. I looked into the facets object, was wondering which sub-parameter should be used to make the plot? proc_out or emcncf_fit? And which columns of values?

Thanks a lot.

@veseshan
Copy link
Collaborator

This R command (almost) reproduces the density plot

plot(density(rep(c(0.89,0.76,0.65), c(9,2,2)), bw=0.006), xlim=c(0.45, 0.95))

Here I have repeated the cf value by number of segments that have it. The input data may have been the cf value repeated by the segment lengths and let R choose the bandwidth automatically.

@zh9118
Copy link
Author

zh9118 commented Apr 16, 2022

This R command (almost) reproduces the density plot

plot(density(rep(c(0.89,0.76,0.65), c(9,2,2)), bw=0.006), xlim=c(0.45, 0.95))

Here I have repeated the cf value by number of segments that have it. The input data may have been the cf value repeated by the segment lengths and let R choose the bandwidth automatically.

Thank you so much. I found cf (from object proc_out$out) and cf.em (from object emcncf_fit$cncf) in the output. Which one should I use? Also, I found these cf density is quite different than the cluster density from the outputted plots. Are they quite different or?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants