Populating Standard Specimen Repository through R

LabKey Support Forum (Inactive)
Populating Standard Specimen Repository through R eva pujadas  2016-09-27 02:20
Status: Closed
 
Dear LabKey team,

We would like to fill the repository via R with data.

On your help-page, you say the following:
https://www.labkey.org/home/Documentation/wiki-page.view?name=specimensHome

"The Standard Specimen Repository supports import of spreadsheet data and a variety of viewing and reporting options.“

Is it possible to fill in data with R in this Standard Specimen Repository?

When we tried, we got the following error message:

Fehler in labkey.insertRows(baseUrl = baseUrl, folderPath = folderPath, :
 HTTP request was unsuccessful. Status code = 403, Error message = Unauthorized

Thanks for your great support!

Eva
 
 
jeckels responded:  2016-09-27 22:51
Hi Eva,

Do you have your specimen repository configured to be editable?

https://www.labkey.org/home/Documentation/wiki-page.view?name=specimenEdit

Do you have a .netrc or other credentials set up for your R script to use for authentication?

Thanks,
Josh
 
eva pujadas responded:  2016-09-28 00:44
Hi Josh,

Thanks for your fast answer.

We are aware of the possibility to configure the repository to be editable, but it is only possible to set the advanced specimen repository to editable, for the Standard Specimen Repository there are no options (see also screenshots). We are running LabKey version 16.2.

About credentials, we have .netrc set up for authentication.

All the best,
Eva
 
Jon (LabKey DevOps) responded:  2016-09-28 11:43
Hi Eva,

That is correct. You cannot edit specimens for a standard repository. This is by design.

If you need it to be editable, please switch the repository from the standard to the Advanced and enable the editable option.

Regards,

Jon
 
eva pujadas responded:  2016-09-30 06:27
Hi Jon,

Thanks for your answer.

Unfortunately, we will not be able to use the specimen repository (neither advanced nor standard) since we need to populate the specimen database very often using the R API.
After trying the advanced repository, we realized that its full functionality only works if one uses the upload of an archive, and not via R (very difficult to fill in correctly all the subtables in LabKey that are used in the background).

In case you would have some alternative suggestion/idea, this would be very welcome.

Best,
Eva