Skip to content
Snippets Groups Projects
Commit 7d2045b0 authored by Maria Voigt's avatar Maria Voigt
Browse files

fixing bugs

mostly paths that have changed
parent 1918327d
No related branches found
No related tags found
No related merge requests found
...@@ -34,7 +34,7 @@ print(paste("indir predictors", indir_predictors)) ...@@ -34,7 +34,7 @@ print(paste("indir predictors", indir_predictors))
year_to_predict <- as.numeric(args[4]) year_to_predict <- as.numeric(args[4])
print(paste("year " , year_to_predict)) print(paste("year " , year_to_predict))
indir_fun <- "../functions" indir_fun <- "~/orangutan_density_distribution/src/functions/"
#-----------# #-----------#
...@@ -45,8 +45,8 @@ source(file.path(indir_fun, "generic/path.to.current.R")) ...@@ -45,8 +45,8 @@ source(file.path(indir_fun, "generic/path.to.current.R"))
print("function loaded") print("function loaded")
# Load coefficients and weights # Load coefficients and weights
coeff_weights_path <- path.to.current(indir, "coeff_weights_abundance", "rds" ) coeff_weights_path <- path.to.current(indir, "coeff_weights", "rds" )
print(paste0("this is coeff_weights_path", coeff_weights_path)) print(paste("this is coeff_weights_path:", coeff_weights_path))
coeff_weights <- readRDS(coeff_weights_path) coeff_weights <- readRDS(coeff_weights_path)
# exclude the first column, which contains models, exclude the coefficient of the # exclude the first column, which contains models, exclude the coefficient of the
# autocorellation term and the weighted aic of the model # autocorellation term and the weighted aic of the model
...@@ -79,7 +79,7 @@ predictor_names <- predictor_names[!grepl("year[:punct:]*", predictor_names)] ...@@ -79,7 +79,7 @@ predictor_names <- predictor_names[!grepl("year[:punct:]*", predictor_names)]
predictor_names <- c("year", predictor_names) predictor_names <- c("year", predictor_names)
# predictors for year on grid # predictors for year on grid
predictors_path <- path.to.current(indir_predictors, paste0("predictors_abundance_grid_", predictors_path <- path.to.current(indir_predictors, paste0("predictors_abundance_",
year_to_predict),"rds") year_to_predict),"rds")
print(paste("this is predictors path", predictors_path)) print(paste("this is predictors path", predictors_path))
predictors <- readRDS(predictors_path) %>% predictors <- readRDS(predictors_path) %>%
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment