The Altair Community is migrating to a new platform to provide a better experience for you. In preparation for the migration, the Altair Community is on read-only mode from October 28 - November 6, 2024. Technical support via cases will continue to work as is. For any urgent requests from Students/Faculty members, please submit the form linked here
W-Logistic only predicts 0 or 1
Maybe I'm doing something wrong but the model learned with W-Logistic always returns 1 or 0 but no other values in between. I looked at the WEKA source code to check if this is correct but unfortunately the WEKA code is not as good as the RM code, so I'm not sure where the problem is.
Maybe the reason is that the label attribute of the learning example set is binominal and the predicted label attribute of the learned regression model must be numerical. The predicted label gets "cloned" from the label of the learning example set (getLabel() in PredictionModel). As far I understand the WEKA code the classifyInstance(Instance instance) method checks if the class of the instance is nominal or not.
Maybe the reason is that the label attribute of the learning example set is binominal and the predicted label attribute of the learned regression model must be numerical. The predicted label gets "cloned" from the label of the learning example set (getLabel() in PredictionModel). As far I understand the WEKA code the classifyInstance(Instance instance) method checks if the class of the instance is nominal or not.
0
Answers
well, since logistic regression is actually an approach to model a binary/binominal classification problem, I do not really see why a logistic regression model should predict any other values than 0 and 1 or the two classes, respectively. As for the confidences, they are of course returned by both Weka and RM logistic learners.
Regards,
Tobias
you could apply a "FeatureGeneration" operator after applying the model. With this operator you can construct the desired feature.
Hope that helps. Cheers,
Ingo
I would like to figure out what method it is using to predict labels and recover the class probabilities for the example set.
no problem: After the learning of a model and the usage of the operator "ModelApplier" a new attribute is added to the exampleset called confidence(y). This confidence is representing the conditioned likelihood p(y|x).
What you call "cutoff" is called "Threshold" - in RapidMiner. The default threshold is 0.5. The applied rule in the case of binary classification problem is:
Let y={0,1} To set another threshold use the operators in the group Postprocessing.
The application of a threshold modifies or addes another attribute called prediction(...).
hope that was helpful
regards,
Steffen
What is the naming convention for the confidence values? This post mentions confidence(y), but I am not getting any success following that lead.
Thanks!
there's a simple way to get to know the attribute names. Simply insert a break point after the model applier using the context menu. Then the intermediate result will be shown and you might check which attributes are present in the data set. You then could simply mark the attributes needed for construction in the meta data view by clicking on the table cell and press Ctrl + C for copying the value into the clipboard and then pasting it in the parameter field. After adapting the parameter, you might press the button for proceeding with the process, using the new parameter values.
And again this will be much simpler in RapidMiner 5
Greetings,
Sebastian
I noticed a type error when it tries to create the feature that I missed yesterday.
[Error] failConfidence: values have to be numerical for numerical attributes: no feature is generated
I change the derived variable type to real, to match the confidence type, and then to numeric, as a catch all. Both gave the same error.
Will RapinMiner 5 allow individual attribute typing?
Thanks for your help!
what do you mean by individual attribute typing? If you mean, that you can set your own, user defined attribute types, then no, this will not work. No operator would know how to handle your user types. If you mean, that you can set the type individually per attribute, then the answer is, that this already works with RapidMiner 4.6, by using an AttributePreprocessing operator chain.
The problems I don't understand, because I don't know what you are doing. The small snippet of the process isn't enough to catch the complete background...
Greetings,
Sebastian