Hi Al,
Thanks for your feedback. I apologize for my delay in replying to your post. I’ve doing some testing today and I confess I am quite puzzled.
If I run the following code I get the already mentioned pval TRUE/FALSE error
cpm_TMM ← read.table(“…/cpm_TMM.mOm.txt”, header = TRUE, row.names = 1, sep = “\t”)
cpm_TMM ← cpm_TMM[apply(cpm_TMM, 1, sd) > 0,]
plsda.Tr ← plsda(t(cpm_TMM), design$Tr, ncomp = 10)
perf.plsda.Tr ← perf(plsda.Tr, validation = “Mfold”, folds = 5, progressBar = FALSE, nrepeat = 10)
However, if I just sample the Tr variable (which obvioudly leads to a wrong variable though) , then I do not get the error anymore. As follows:
cpm_TMM ← read.table(“…/cpm_TMM.mOm.txt”, header = TRUE, row.names = 1, sep = “\t”)
cpm_TMM ← cpm_TMM[apply(cpm_TMM, 1, sd) > 0,]
plsda.Tr ← plsda(t(cpm_TMM), sample(design$Tr), ncomp = 10)
perf.plsda.Tr ← perf(plsda.Tr, validation = “Mfold”, folds = 5, progressBar = FALSE, nrepeat = 10)
Error in if (pval < alpha) { :
valeur manquante là où TRUE / FALSE est requis
I’ve allowed myself to create a link to both the dataset and the design data frames in case you wanted to have a look
https://mycore.core-cloud.net/index.php/s/mdB1aKUh6zCezSq
I thank you for your help.
Best,
David