Orange Forum • View topic - Can examples have labels?

Can examples have labels?

A place to ask questions about methods in Orange and how they are used and other general support.

Can examples have labels?

Postby monarchi » Mon Jul 15, 2013 22:58

Hello -

My apologies for asking a question that I asked before, but I didn't get any replies, and I suspect that I asked it incorrectly.

In brief my research always has uniquely labeled examples, even if they number in the thousands (the general domain is text mining and network analysis). I badly need to be able to show the label for each example in my visualizations, even if I have to zoom in to read it. So far I cannot figure out how to indicate in the file input process that an attribute is a label. In addition, it seems that some attributes are automatically identified as class attributes or meta attributes. In general I have neither although during the process of data exploration I may identify some classes and subsequently want to label them.

I have searched the documentation for this and tried to find a tutorial or video explaining how to do it, but have been unsuccessful.

Any guidance or assistance would be greatly appreciated. And, again, I apologize for restating the question. I'm really quite baffled.

Thank you.

David

Re: Can examples have labels?

Postby Ales » Tue Jul 16, 2013 10:17

monarchi wrote:So far I cannot figure out how to indicate in the file input process that an attribute is a label

Use the string attribute to denote a label. For instance
Code: Select all
Label  A1  A2
string c   c

A      1   2
ABC    3   4
(replace space character formatting by tabs)

monarchi wrote:In addition, it seems that some attributes are automatically identified as class attributes or meta attributes.

You can use the 'Select Attributes' widget to move attributes between regular/class/meta.

Re: Can examples have labels?

Postby monarchi » Tue Jul 23, 2013 22:25

Thanks for the information, Ales. I believe I'm missing something, though. I configured my data following your example with Label, A1, A2, ... in the first row, then string, c, c, .... for the numeric attributes in the second row, followed by a blank line before the actual data.

However the second row is read as a set of data, not as descriptions of the data. I can't see what I have missed in the input process. It's true that I can exclude the row containing string, c, c, ... in the Data Table widget, but I can't get the Label attribute to behave as a label.

Any assistance would be appreciated.

Thank you.

David

PS: What does "c" stand for?

Re: Can examples have labels?

Postby Ales » Wed Jul 24, 2013 11:26

monarchi wrote:However the second row is read as a set of data, not as descriptions of the data. I can't see what I have missed in the input process. It's true that I can exclude the row containing string, c, c, ... in the Data Table widget, but I can't get the Label attribute to behave as a label.

This is most commonly a problem with inconsistent use of tabs to separate the data cells. Also make sure to name your input file with the '.tab' extension.
monarchi wrote:PS: What does "c" stand for?
'continuous'

Re: Can examples have labels?

Postby monarchi » Fri Jul 26, 2013 0:00

Thank you once again, Ales. As I suspected, it was a rank newbie error on my part - I had not used a tab file extension although I had used tabs to delimit the fields. I apologize for taking up your and others time on the forum. :$

Best regards,
David


Return to Questions & Support



cron