Skip to menu

plot_ROC() 문의드립니다.

닥터강 2020.03.24 15:23 Views : 22737

안녕하세요 교수님

데이터 분석중에 다음과 같은 오류가 나서 문의드립니다.


> plot_ROC(b1,b2)

Setting levels: control = Control, case = LBD

Setting direction: controls > cases

Error in wilcox.test.default(x$lr$model[, 2], x$lr$model[, 1]) : 

  'y' must be numeric


제 데이터의 경우 종속변수(control or LBD)가 factor로 되어 있는데요, 이 때문에 문제가 발생하는 것인지요?

해결책이 무엇이 있을지 문의드립니다. 새로운 열을 numeric으로 만들어서 진행을 하는 방법 외에 다른방법은 없을지요? 감사합니다.!