You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to obtain the following graph using the timeVariation plot. I must say that I had been generating these graphs since a long time ago.
Anyway, when I ran my code a few days ago I received this error from R Error in mutate(): ℹ In argument: wkday = wday(date, label = TRUE, abbr = FALSE). Caused by error in factor(): ! invalid 'labels'; length 6 should be 1 or 7.
What I could verify by making some tests in the source code is that the label argument of the function is not working properly, so what worked for me was changing this part of the code
Now, despite the fact that this change helped solving the error, I could not implemented it, because when trying to define the function with this change and running it in my main code, some reiterative non defined functions and dependencies were asked and I gave up trying.
Steps to reproduce
Using the following code you can check the error
library(openair) mary <- importAURN(site = "my1", year = 2000)
timeVariation(mary, pollutant = 'no2', type = 'month')
Openair version
‘2.18.2’
The text was updated successfully, but these errors were encountered:
Bug description
I am trying to obtain the following graph using the timeVariation plot. I must say that I had been generating these graphs since a long time ago.
Anyway, when I ran my code a few days ago I received this error from R
Error in mutate(): ℹ In argument: wkday = wday(date, label = TRUE, abbr = FALSE). Caused by error in factor(): ! invalid 'labels'; length 6 should be 1 or 7
.What I could verify by making some tests in the source code is that the label argument of the function is not working properly, so what worked for me was changing this part of the code
mydata <- mutate(mydata, wkday = wday(date, label = TRUE, abbr = FALSE), wkday = ordered(wkday, levels = day.ord), hour = hour(date), mnth = month(date))
for this one
mydata <- mutate(mydata, wkday = day.ord[wday(date)], wkday = ordered(wkday, levels = day.ord), hour = hour(date), mnth = month(date))
Now, despite the fact that this change helped solving the error, I could not implemented it, because when trying to define the function with this change and running it in my main code, some reiterative non defined functions and dependencies were asked and I gave up trying.
Steps to reproduce
Using the following code you can check the error
library(openair) mary <- importAURN(site = "my1", year = 2000)
timeVariation(mary, pollutant = 'no2', type = 'month')
Openair version
‘2.18.2’
The text was updated successfully, but these errors were encountered: