I am having below R code. when I am plotting this in power BI desktop it is working fine as Reason col is coming as category. When I am publishing same in power BI service, Reason is converted into the number and date col is also changed. attached screen shot for reference.enter image description here
source('./r_files/flatten_HTML.r')
############### Library Declarations ###############
libraryRequireInstall("ggplot2");
libraryRequireInstall("plotly");
libraryRequireInstall("XML");
libraryRequireInstall("dplyr");
libraryRequireInstall("reshape2")
####################################################
dataset <- Values
g<-ggplot(data = dataset, aes(x=as.Date(Date), y=Reason, label = Time ))
####################################################
############# Create and save widget ###############
p = ggplotly(g);
internalSaveWidget(p, 'out.html');
####################################################
here is the data I have .
Time ShortName Reason Date
D Response to 31/05/2019 0:00
31 D Issued 15/04/2019 0:00
D Return 12/06/2019 0:00
B Return 9/11/2018 0:00
C Return 11/02/2019 0:00
C Return 13/03/2019 0:00
D Return 2/07/2019 0:00
A Return 23/09/2019 0:00
D Response to 20/06/2019 0:00
10 D Return 11/06/2019 0:00
21 D Return 2/05/2019 0:00
54 A Return 8/07/2019 0:00
1 A Issued Outside 5/07/2019 0:00
1 A Issued Outside 20/09/2019 0:00
5 D Response to 25/06/2019 0:00
6 D Response to 31/05/2019 0:00
9 C Issued 29/01/2019 0:00
10 D Issued 15/04/2019 0:00
A Issued Outside 20/09/2019 0:00
D Response to 31/05/2019 0:00
10 D Issued 15/04/2019 0:00
55 A Issued Outside 5/07/2019 0:00