Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Line graph question

I have one column of dates and another column with four different options of text, like "A," "B," "C", and "D." How can I create a line graph that will give me four separate lines for each text option to show how many times each one occurred on a monthly basis?

4 Replies
Nicole-Smith
MVP
MVP

You'll want two dimensions and one expression.

Dimensions:

  • Date
    • This will show across the x-axis if you set it as the first dimension
  • Option
    • This will show a different line for each value in this field

Expressions:

  • count(Option)
    • This will determine where the lines get plotted
Anonymous
Not applicable
Author

I understand how to set date as a dimension but can you explain a little more how to create the option dimension and how it relates to the column with the text that it's referencing?

Thanks

ychaitanya
Creator III
Creator III

Dim :  Month (Date_Dim)

Expr1 :  Count(distinct {<Option={"A"}>}Options)

Expr@ :  Count(distinct {<Option={"B"}>}Options)

Expr3 :  Count(distinct {<Option={"C"}>}Options)

Expr4 :  Count(distinct {<Option={"D"}>}Options)

Thanks

CY

Nicole-Smith
MVP
MVP

So you don't have a column in your data with the Option data?  If you do, that's the column you want as your second dimension.

If not, can you please give a few lines of example data so I can understand what you're working with?