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

Error of netROC function #2

Open
TarsLi opened this issue May 31, 2022 · 5 comments
Open

Error of netROC function #2

TarsLi opened this issue May 31, 2022 · 5 comments

Comments

@TarsLi
Copy link

TarsLi commented May 31, 2022

Hi,
I tried to use the NetMoss2 to identify some biomarkers in multiple diseases, however, an error occurred when I tried the netROC function using the testdata. The error information is "Error in y - ymean: non-numeric argument to binary operator", then I change the column type column of the metadata file to binary (healthy:0; disease:1) and the error is gone. After that, another error appeared: Error in order (importance_rf$MeanDecreaseAccuracy, decreasing = T): argument 1 is not a vector“. So could you please offer me some suggestions? Thanks!

@xiaolw95
Copy link
Owner

xiaolw95 commented Jun 1, 2022

Which data have you used, single or multiple? How about trying to set the "type" column of the metadata as factors?

@TarsLi
Copy link
Author

TarsLi commented Jun 1, 2022

I used the example for multiple files. Setting the column "type" of the metadata as factors worked.
Another question is about the abundance files, is it feasible to use only some of the high prevalence genera to identify the key taxon? In other words, the total abundance of these genera is less than 100% and there is variation between samples. Thanks!

@xiaolw95 xiaolw95 closed this as completed Jun 2, 2022
@xiaolw95 xiaolw95 reopened this Jun 2, 2022
@xiaolw95
Copy link
Owner

xiaolw95 commented Jun 2, 2022

Technically, it's ok to use the highest prevalence genera to do your job.
The point is how you construct the ecological network. It's a complicated problem actually. In short, if too many nodes are missing, the co-occurrence network you build may not reflect the authentic ecological interaction. NetMoss indeed has the ability to identify the key taxon as long as there are differences between case and control networks; however, in this case, the results need further confirmation.

@Damianyangyang
Copy link

Damianyangyang commented Jul 24, 2022

@xiaolw95 @TarsLi
Hi~,I got this error when I ran the netROC, do you know why?
netROC(case_dir = case_dir, control_dir = control_dir, marker = marker, metadata = metadata, plot.roc = TRUE, train.num = 1)
image

@xiaolw95 xiaolw95 reopened this Aug 24, 2022
@xiaolw95
Copy link
Owner

@xiaolw95 @TarsLi Hi~,I got this error when I ran the netROC, do you know why? netROC(case_dir = case_dir, control_dir = control_dir, marker = marker, metadata = metadata, plot.roc = TRUE, train.num = 1) image

Sorry for the delayed reply. There was something wrong with the read command of metadata and now has been fixed. You can try it with the NEW VERSION.

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

3 participants