Code Monkey home page Code Monkey logo

microbial's People

Contributors

guokai8 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

microbial's Issues

Rearrange sample in Taxonomy plot based on groups

Hi Kai,

I need help in rearranging samples in the results of my taxonomy plot based on groups and relative abundance.

I used this script and produce this:

plotbar(norm,level="Phylum")
e3e15255-47e7-4f36-b54c-0b07e75cea9d

I want to reorder my samples like this:
sampleorder <- c(Control=c("YHY", "LJH", "KSH", "HSO", "LCH", "KHK", "HMG", "GYJ", "NYJ", "CYY"),(Patient=c("GSJ_R", "GSJ_L", "JSA_R", "OJY_L", "OJY_R", "CCS_L", "CCS_R", "PIR_R", "LEJ_L", "JSA_L", "LEJ_R", "KEJ_R", "KEJ_L", "PIR_L")))

Thanks
James

ldamarker error

Hi Kai,

I get this error whenever I try these scripts in R:

ps
phyloseq-class experiment-level object
otu_table() OTU Table: [ 1052 taxa and 24 samples ]
sample_data() Sample Data: [ 24 samples by 2 sample variables ]
tax_table() Taxonomy Table: [ 1052 taxa by 8 taxonomic ranks ]

pp <- ldamarker(ps, pvalue = 0.05, normalize = TRUE, method = "relative")
Normalization using relative method
Error in $<-.data.frame(*tmp*, "tax", value = character(0)) :
replacement has 0 rows, data has 25248

May I ask some advice on how to resolve this.

Thanks
James

Blank plot for plotLDA()

Thanks for providing this package.
I am trying to use it for plotting LDA.

The res table that I get from the function successfully, but when I use:

res <- ldamarker(ps_1,group="breastfeeding_group")
head(res,10)
# A tibble: 10 x 13
# Groups:   rank, tax [10]
   rank  tax      statistic p.value parameter method   p.adj `exclusive brea… `non-exclusive …   max
   <chr> <chr>        <dbl>   <dbl>     <int> <chr>    <dbl>            <dbl>            <dbl> <dbl>
 1 Class D_0__Ar…    1.00   0.316           1 Kruskal… 0.739              NA               NA    NA 
 2 Class D_0__Ba…    0.184  0.668           1 Kruskal… 0.872              NA               NA    NA 
 3 Class D_0__Ba…    1.13   0.288           1 Kruskal… 0.739              NA               NA    NA 
 4 Class D_0__Ba…    1.31   0.253           1 Kruskal… 0.739              NA               NA    NA 
 5 Class D_0__Ba…    0.0412 0.839           1 Kruskal… 0.955              NA               NA    NA 
 6 Class D_0__Ba…    2.28   0.131           1 Kruskal… 0.626              NA               NA    NA 
 7 Class D_0__Ba…    7.41   0.00649         1 Kruskal… 0.287             406.            1861. 1861.
 8 Class D_0__Ba…    3.83   0.0504          1 Kruskal… 0.510              NA               NA    NA 
 9 Class D_0__Ba…    0.169  0.681           1 Kruskal… 0.872              NA               NA    NA 
10 Class D_0__Ba…    0.144  0.704           1 Kruskal… 0.876              NA               NA    NA 
# … with 3 more variables: min <dbl>, LDAscore <dbl>, direction <chr>
plotLDA(res,group=c("exclusive breastfeeding","non-exclusive breastfeeding"),lda=5,pvalue=0.05)

The plot that generated is blank, only has a x-axis label.

Could you help me to address it ?
Thanks!

lda plot for more than 2 groups

plotLDA(res,group=c("week_1","week_4", "week_24"),lda=2, pvalue=0.05)
Error: Insufficient values in manual scale. 3 needed but only 2 provided.

Is it possible to plot LDA for more than 2 groups?

Thanks

ldamarker output table

Hi! I wanted to know what these values are in the output table from ldamarker, I cant seem to find it anywhere in the documentation:
statistic, min and max.

Thank you!
Salma

Taxa labels for plotLDA

I have sub-grouped the LDA plots by taxonomic level. However, I would only like to have the last rank name on the plot (e.g. phylum, genus etc) rather than the full string from Kingdom down.

I am struggling to manipulate the tax object to do this as it is a long string. Is there any chance there is an easy solution to this issue?

Thank you!
Susanne

Citation

Hi Kai

How do I cite the microbial package in the paper ?

Hesham

Error in `$<-.data.frame`

res <- ldamarker(ps.nonc.nocyano,group="SampleType")
Normalization using relative method
|========================================================================================================= |100% ~0 s remaining Error in $<-.data.frame(*tmp*, "direction", value = c("PFH", "SUH" :
replacement has 2 rows, data has 1
plotLDA(res,group=c("CFH","SUH"),lda=5,pvalue=0.05)
Error in subset(x, LDAscore > lda) : object 'res' not found

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.