Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Need help

Hi all  i want to create a line chart by using below data.

 

datetimedate1time1file
1/1/20205:00:00 PM43831.000.71hp_ORG.txt
1/2/20207:00:00 PM43832.000.79hp_ORG.txt
1/3/20206:00:00 PM43833.000.75hp_ORG.txt
1/4/20204:00:00 PM43834.000.67hp_ORG.txt
1/5/20206:30:00 PM43835.000.77hp_ORG.txt
1/6/20204:20:00 PM43836.000.68hp_ORG.txt
1/7/20204:00:00 PM43837.000.67hp_ORG.txt
1/8/20207:00:00 AM43838.000.29hp_ORG.txt
1/9/20202:00:00 PM43839.000.58hp_ORG.txt
1/10/20201:00:00 PM43840.000.54hp_ORG.txt
1/11/20204:00:00 PM43841.000.67hp_ORG.txt
1/12/20206:00:00 PM43842.000.75hp_ORG.txt
1/13/20201:00:00 PM43843.000.54hp_ORG.txt
1/14/20206:00:00 PM43844.000.75hp_ORG.txt

 result like blow chart im new to PBI can anyone help here

  • Anonymous ,

     

    Currently the aggregation way of "time" type data can only be "count" in line chart so I'm afraid you can't use line chart, you can install python and matplotlib package then create a pychart in power bi.

    https://docs.microsoft.com/en-us/power-bi/desktop-python-visuals

     

    Community Support Team _ Jimmy Tao

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

     

     

3 Replies

  • Greg_Deckler's avatar
    Greg_Deckler
    Community Champion

    Well, if you can deal with a 24 hour clock, I can get you there. See attached. The trick is this column:

     

     

    Column = 
        VAR __DecimalTime = [time] * 1.
        VAR __Hours = INT(__DecimalTime * 24)
        VAR __Minutes = (__DecimalTime * 24 - __Hours) * 60
    RETURN
        __Hours * 100 + __Minutes

     

     

    And then you use the Chelsea Eiden's Duration trick to format it. https://community.powerbi.com/t5/Quick-Measures-Gallery/Chelsie-Eiden-s-Duration/m-p/793639#M389

     

    • Anonymous's avatar
      Anonymous
      Not applicable

      thanks for your reply.

       

      but still i cant see the y axis  in my expected format ๐Ÿ˜ž

  • v-yuta-msft's avatar
    v-yuta-msft
    Community Support

    Anonymous ,

     

    Currently the aggregation way of "time" type data can only be "count" in line chart so I'm afraid you can't use line chart, you can install python and matplotlib package then create a pychart in power bi.

    https://docs.microsoft.com/en-us/power-bi/desktop-python-visuals

     

    Community Support Team _ Jimmy Tao

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.