Skip to content

Commit

Permalink
Try importing Billa Billa data
Browse files Browse the repository at this point in the history
  • Loading branch information
IhsanKhaliq committed Jun 2, 2021
1 parent 1eb4586 commit ac28ee8
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 29 deletions.
58 changes: 29 additions & 29 deletions R/trace_asco.R
Original file line number Diff line number Diff line change
Expand Up @@ -44,35 +44,35 @@
#' @export
#'
#' @examples
#' # First weather data needs to be imported and formated with `format_weather`
#' Newmarracarra <-
#' read.csv(system.file("extdata",
#' "1998_Newmarracarra_weather_table.csv", package = "ascotraceR"))
#' station_data <-
#' system.file("extdata", "stat_dat.csv", package = "ascotraceR")
#'
#' weather_dat <- format_weather(
#' x = Newmarracarra,
#' POSIXct_time = "Local.Time",
#' temp = "mean_daily_temp",
#' ws = "ws",
#' wd_sd = "wd_sd",
#' rain = "rain_mm",
#' wd = "wd",
#' station = "Location",
#' time_zone = "Australia/Perth",
#' lonlat_file = station_data)
#'
#'
#' traced <- trace_asco(
#' weather = weather_dat,
#' paddock_length = 100,
#' paddock_width = 100,
#' initial_infection = "1998-06-10",
#' sowing_date = as.POSIXct("1998-06-09"),
#' harvest_date = as.POSIXct("1998-06-09") + lubridate::ddays(30),
#' time_zone = "Australia/Perth",
#' primary_infection_foci = "center")
# First weather data needs to be imported and formatted with `format_weather`
Billa_Billa_weather <-
read.csv(system.file("extdata",
"2020_Billa_Billa_weather.csv", package = "ascotraceR"))
station_data <-
system.file("extdata", "stat_dat.csv", package = "ascotraceR")

Billa_Billa_weather <- format_weather(
x = Billa_Billa_weather,
POSIXct_time = "Local.Time",
temp = "mean_daily_temp",
ws = "ws",
wd_sd = "wd_sd",
rain = "rain_mm",
wd = "wd",
station = "Location",
time_zone = "Australia/Perth",
lonlat_file = station_data)


traced <- trace_asco(
weather = weather_dat,
paddock_length = 100,
paddock_width = 100,
initial_infection = "1998-06-10",
sowing_date = as.POSIXct("1998-06-09"),
harvest_date = as.POSIXct("1998-06-09") + lubridate::ddays(30),
time_zone = "Australia/Perth",
primary_infection_foci = "center")
trace_asco <- function(weather,
paddock_length,
paddock_width,
Expand Down
File renamed without changes.
File renamed without changes.

0 comments on commit ac28ee8

Please sign in to comment.