質問

I have already generated a huge train file of ~1GB in which the ground truth is one of 4 classes {-1,0,1,2}. Yes, I agree that I could have done it using 3 instead of -1, but for some conventional reasons I used -1.

I want to use gbm in multinomial distribution mode. Whether it will create some problem with a negative representation or I can proceed with it?

役に立ちましたか?

解決

The numerical values will be converted to factor variables and the labels will be {-1,0,1,2}. The -1 label will not be a problem.

You will not get a reference value for the "0" category unless you create the factor variable first with var <- factor(x, levels=c("0", "1", "2", "-1"). (I'm not sure that it would be meaningful to be talking about a reference level in this situation, but worried that you thought the would be a special significance for the "0"-level.)

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top