How to count daily occurrences?

pusercpuserc MemberPosts:6Contributor I
edited December 2018 inHelp

Hi,
I have a data source where each row consists of a id and a date . How do I get the amount of ids per day; so that i can work on this time serie.

Thank you

Tagged:

Answers

  • sgenzersgenzer Administrator, Moderator, Employee, RapidMiner Certified Analyst, Community Manager, Member, University Professor, PM ModeratorPosts:2,959Community Manager

    hello@puserc- so without the ability to look at your data and your process (did you read the instructions when you were posting this message?:)), it is hard to say exactly. It sounds like you need to do a simple Aggregate by day. But you may need to add a new feature if you have more than one timestamp per day. Can you please post the data and XML?


    Scott

    puserc
  • rfuentealbarfuentealba Moderator, RapidMiner Certified Analyst, Member, University ProfessorPosts:568Unicorn

    Hi@puserc,

    Like@sgenzersaid, you need a simple aggregation.

    However, I assume you have datetimes somewhere, so here is an example for you, a process that generates the day, month and year separately, creates an aggregation filtering by these columns, generating dates from days, months and years, and selecting only the required fields. The only "weird" thing I used was theCreate ExampleSetoperator that is included in theOperator Toolboxextension of RapidMiner, but you can get rid of it and connect your data.


    < context>

    <输出/ >
    <宏/ >






































    < connect from_op="Create ExampleSet" from_port="output" to_op="Generate Attributes" to_port="example set input"/>
    < connect from_op="Generate Attributes" from_port="example set output" to_op="Aggregate" to_port="example set input"/>
    < connect from_op="Aggregate" from_port="example set output" to_op="Generate Attributes (2)" to_port="example set input"/>
    < connect from_op="Generate Attributes (2)" from_port="example set output" to_op="Select Attributes (2)" to_port="example set input"/>
    < connect from_op="Select Attributes (2)" from_port="example set output" to_port="result 1"/>






    That way you'll have a lot to work with.

    All the best,

    Telcontar120 sgenzer puserc
Sign InorRegisterto comment.