We saved our model as model.RData and model.rds files, then we assigned them as resources in our project as R data file - Opal and RDS data file -Opal (path set as : /projects/my_project/model.RData).
Most likely because the file retrieval from Opal failed (thus the empty file).
How have you created this resource: using the web interface or an R script?
Can you verify that the credentials of the resource are correct? It must be a personal access token.
When you test with R, in opal.login(), do not use both username/password and token, because token will be ignored. Use one authentication method or the other.
That way you can be sure the local path were the files of interest are located and properly format the resource URL, as well as veryfying that the R session can actually see the path.
On the proposed code I can see the file xxx.Rdata; so I would create a resource as:
opal.resource_create(o, 'project', 'resource', 'file:///var/lib/rserver/work/projects/Athlete/xxx.Rdata',
format = 'Rdata')
Hello Yannick, Thank you the script, am trying to load data as resource using this script but when i tried to use the resource i get an error datashield.assign.resource(conns, “client”, “test.mtcars1”)
Assigned all resource (client ← …) [=======================>------------------------] 50% / 0sError: $demo
[1] “[Client error: (403) Forbidden] HTTP 403 Forbidden” . When i try with the administrator account i was able to use the resource. I also tried assigning permission to the user group but same error.