/
library_program_set_settings ()

library_program_set_settings ()

Function prototype

library_program_set_settings ( session, settings )

API VersionAll

Modifies PROGRAM properties

Input

  • session: is the session id obtained in the session_init call
  • settings: settings XML with program's settings
    • trial: (true/false) To indicate whether the PROGRAM is a TRIAL or not. Note that If the PROGRAM OBJECT is already a TRIAL, then it may not be possible to change this property to false. This restriction occurs when the PROGRAM contains WORKPLANS that have been assigned to a specific "trial group" (Intervention or Control)
    • randomized: (true/false) This parameter is ignored if the PROGRAM is not a "TRIAL"
    • randomize_settings: Properties to define how to apply randomization. This node is only returned in "TRIAL" PROGRAMS configured as RANDOMIZED. Introduced in API Version 2.7.21
      • mode: This property defines the algorithm used to apply randomization (how to assign an ADMISSION to either the "Intervention" or "Control" trial groups).. Possible values:
        • 1: Manual randomization. A TASK will be inserted in each ADMISSION to let the professional choose the TRIAL group (Intervention or Control). This was the default value in API versions before 2.7.21
        • 2: Automatic randomization: Linkcare platform will decide automatically the trial group for each ADMISSION
      • stratification_var: Allows to define the name of a variable that will be used to stratify the randomization. This parameter only makes sense when the randomization mode is "automatic". The name of the variable must be an ITEM_CODE. If no value is provided, the selection of the trial group will be a simple random choice between "Intervention" and "Control"
    • double_blind: (true/false) This parameter is ignored if the PROGRAM is not a "TRIAL"
    • N: (true/false) This parameter is ignored if the PROGRAM is not a "TRIAL". This value represents the size of the sample expected for a trial
    • stratified
    • duration: Maximum duration of the ADMISSIONS in this PROGRAM. If no value (or 0) is assigned, the duration is assumed to be infinite. If a duration is specified, the ADMISSIONs still active that were enrolled before that duration value will be discharged automatically. Introduced in API version 2.7.22.
      NOTE: The value assigned to this property may be overridden by the SUBSCRIPTION configuration
      • value: Number of units of duration. If 0 or empty, an infinite duration is assumed
      • unit: Units used to define the duration (DAYS, WEEKS, MONTHS, YEARS)
    • locked
    • events_disabled
    • predefined_events. Indicates if a PROGRAM should permit the creation of predefined EVENTS. Introduced in API Version 2.7.12
    • manual_admissions_enabled: indicates if a PROGRAM should permit the creation of ADMISSIONs manually. This is only a recommendation for the client application, who is responsible of permitting a user to create a new ADMISSION from the interface. The purpose of this property is to indicate that the ADMISSIONS should only be created programatically. Introduced in API Version 2.7.16

Output

  • result: empty
  • ErrorMsg: If any error occurs, then this value contains a description of the error translated to the current language
  • ErrorCode: If any error occurs, then this value contains any of the standard ERROR CODES

Request Sample

library_program_set_settings ("LC0000.0000000000",


<settings>
    <trial>true</trial>
    <randomized>true</randomized>
    <randomize_settings>
      <mode>2</mode>
      <stratification_var>HEMODIALISIS_TYPE</stratification_var>
    </randomize_settings>
    <double_blind>true</double_blind>
    <N>undefined</N>
    <stratified>true</stratified>
    <exclusion_inclusion_criteria>true</exclusion_inclusion_criteria>
    <duration>
      <value>5</value>
      <unit>months</unit>
    </duration>
    <locked>true</locked>
    <events_disabled>false</events_disabled>
    <predefined_events>true</predefined_events>
    <manual_admissions_disabled>false</manual_admissions_disabled>
</settings>

)

ResponseSample

<?xml version="1.0" encoding="UTF-8"?>

<result></result>

<ErrorMsg></ErrorMsg>

<ErrorCode></ErrorCode>

Related content