ETHZ-INS / DLCAnalyzer

R Scripts to analyze deep lab cut point data and related data
GNU General Public License v3.0
60 stars 16 forks source link

Issue when plotting the data, says object "x"not found #24

Open Annabete opened 3 months ago

Annabete commented 3 months ago

Hi,

I am running in a very weird problem. We use a server to process the data, so there are two different behaviours being analysed. The filtered csv from one behavior loaod normally and can all be plotted. However, the same type of csv files but created with a different training module will be read and processed but I try to run the same plotting code it gives me a massive error:

Error in `geom_path()` at AnnaElisabete/Downloads/DLCAnalyzer_Functions_final.R:1253:5:
! Problem while computing aesthetics.
 Error occurred in the 1st layer.
Caused by error:
! object 'x' not found
Backtrace:
  1. global PlotPointData(Tracking, points = c("Body 2", "Tail"))
  2. cowplot::draw_plot(...)
       at AnnaElisabete/Downloads/DLCAnalyzer_Functions_final.R:1253:5
  4. cowplot:::as_grob.ggplot(plot)
  5. ggplot2::ggplotGrob(plot)
     ...
 18. ggplot2 (local) f(l = layers[[i]], d = data[[i]])
 19. l$compute_aesthetics(d, plot)
 20. ggplot2 (local) compute_aesthetics(..., self = self)
 21. base::lapply(aesthetics, eval_tidy, data = data, env = env)
 22. rlang (local) FUN(X[[i]], ...)
Error in geom_path() : Error occurred in the 1st layer. Caused by error: ! object 'x' not found