Creating an assay in the LabKey Server using an R script

LabKey Support Forum
Creating an assay in the LabKey Server using an R script niloofar nickaeen  2024-01-04 23:49
Status: Active
 

Hi.
I have used Rlabkey to create lists and manipulate data on those lists. However, now I need to create assays.
labkey.create.domain() which I have used to create lists, accepts the folowing domain types and assays are not an option:

• "IntList": A list with an integer key field
• "VarList": A list with a string key field
• "StudyDatasetVisit": A dataset in a visit based study
• "StudyDatasetDate": A dataset in a date based study
• "IssueDefinition": An issue list domain
• "SampleSet": Sample set
• "DataClass": Data class

Can you please guide me through creating an assay using an R script?

Thank you.

 
 
mohara responded:  2024-01-09 10:54

Hi Niloofar:

LabKey assay designs are a combination of several domains, and there isn't an API for creating that assay design itself. You can create the design using the UI (simplest, and covers a great many use cases) and then add runs/batches using the experiment.saveBatch API, though that also isn't as straightforward as using the UI or simply file import automation to add assay runs and data. Learn more here:

Another option if needed is to add a file-based assay design in a module, though that would likely involve more support than I can provide here. You can learn more about what's involved in an assay design in the documentation here:

I know my colleague Jason also reached out to you by email, so I'd be happy to follow up there as needed.

Thanks,
--Molly