Options

Data from long to wide format

windswinds Member Posts: 4 Contributor I
edited November 2018 in Help
I have some data I get from a SQL query like this:

[tt]Group    Value
1            12
1            14
2            23
2            24
...
[/tt]

and I'd like to output it to a file like this:

[tt]1    12,14,...
2    23,24,...
[/tt]

How can I do this with RapidMiner?

Thanks.

Answers

  • Options
    SebastianLohSebastianLoh Member Posts: 99 Contributor II
    Hi winds,

    what you are looking for is the Pivot operator. Search for "pivot" in this forum and especially in the the Community Extension (View -> MyExperiment Browser) and you will find several examples how to use it.

    However, you'll need an index/item  attribute, eg.

    Group    Value  Index/Item
    1            12          1
    1            14          2
    2            23          1
    2            24          2
    ...

    Ciao Sebastian
Sign In or Register to comment.