AskiaTools 5.6
This article provides a summary of the new features available in AskiaTools v5.6
Table of contents
- Random data generation
- New command line parameters :
- Export to an Askia survey
- SAV export new options
- Verification script improvements
Random data generation
- Pre-defined responses
We have added a script window to enter some code to be run prior to the random generation.
This allows you to generate data for a specific population, ignore screenout routings etc.
If the option `Overwrite existing data if visible` is checked then routing instructions you have set in your survey could be overwritten by the random data generation. - RDG accessible through command line
Here are the parameters you can use when running RDG through command line :
Parameter | Type | Description |
/generateinterviews | - | Flag used to request a random data generation. |
/numOfInterviews | Integer | Determines the number of interviews that will be randomly generated. (default value 100) |
/attemptsPerQuestion | Integer | Indicates the number of times a generation is attempted for a question when getting an entry error. (default value 10) |
/scenario | String | String that specifies the name of the scenario used for the RDG. |
/SaveIfTooManyAtempts | Integer | Indicates if the interview should be saved after unsuccessful attempts for a question. (possible values 0 or 1, default 1) |
/SaveIfScreenOut | Integer |
Indicates if the interview should be saved if screened out. (possible values 0 or 1, default 1) |
/randomseed | Integer | Indicates which reproducible way of generating interviews (the value is different at each call). |
/definitionfile | String | String that indicates the path of the script to run. |
/OverwriteIfVisible | Integer | Indicates if a question data should be re-generated when it’s already filled if it’s visible. (possible values 0 or 1, default 0) |
/routingspeed | Integer | Indicates if the speed of the routings should be logged. (possible values 0 or 1, default 0) |
/modules | String | String that indicates the path of the module (separated by comma if several modules) to use during RDG. |
/quotasource | Integer |
0 : no quota 1 : quota from the QEX 2 : quota from LiveSurvey (default 0) |
Ex :
Tools.exe "C:\Qes\MyFile.qes" /generateinterviews /numOfInterviews:1000 /attemptsPerQuestion:10 /SaveIfScreenOut:1
A definition of these options can be found here.
New command line parameters
- Questionselection
Using AskiaScript you can select the variables you want to export (in ASCII delimited, SAV, SPSS Dimensions, Triple S or Askia survey format) based on their properties (tag, type, IsAnonymised etc.).
For example the script below will select all open ended and datetime questions./questionselection:"(CurrentQuestion.Type has {\"open\";\"datetime\"})"
You can find more examples here
- Export to SPSS Dimensions from the command line
Use the parameter /exportdimensions to export your data from Askia to SPSS Dimensions format.
Tools.exe "C:\Qes\MyFile.qes" /exportdimensions /completes /datafile:"Provider=mrOleDB.Provider.2;Persist Security Info=False;Data Source=mrDataFileDsc;Location=C:\Qes\Me\ExportDimensions\DataOut.dzf;Extended Properties=\"\";Initial Catalog=C:\Qes\Me\ExportDimensions\ExportData.mdd;Mode=ReadWrite;MR Init MDM Access=1" /questions":gender;age"
- Clean caption before export
We've added two new parameters:
- /removehtml : removes all HTML tags inserted in your survey captions.
- /removeaskiascript : replaces Askia's inline scripts used in your survey captions with "_".
Tools.exe "C:\My Directory\CleanCaption.qes" /type:0 /exportdelimited /completes /closedtype:2 /removehtml /removeaskiascript /questioncaption:3 /datafile:"C:\My Directory\Cleaned.txt"
The parameters listed above can be used with /exportdelimited, /exportsav, /exporttriples, /exportqes.
- Export peri data (system fields)
We have added a new function (only avaiable from the command line) to get the peri data of a survey by using the parameter /exportperidata.
Tools.exe "C:\Qes\Ex.qes" /exportperidata /completes /datafile:"C:\Qes\Output.txt" /fields:"seed;fraudinformation"
If you do not specify the fields (using the parameter /fields) or leave it empty then all possible fields will be exported.
To specify the ones you want, separate them by a semi-colon among this list:InterviewID AgentId StartInterview EndInterview Seed CallId Completed LanguageId KeyStrokeCount ErrorsOnVerifyCount Guid LastResult LastSubResult CallCount Revision WebIdentity Resolution Capabilities Broker BrokerPanelId Longitude Latitude PanelId ListId StartInterviewUTC EndInterviewUTC StartInterviewUTCOffset EndInterviewUTCOffset LastSeenQuestion DeviceId ClickCount Speed Duration FraudInformation ExternalCalls CollectionMode
Export to an Askia survey
We have create a new type of export : Export to Askia survey.
It allows you to export a survey file to:
- QES file format.
- QEX/Inverted format.
- Field through the CcaWebAPI (SQL format).
The screens and routings are not exported but the question, responses, languages and data is.
All options are accessible through command line.
Parameter | Type | Description |
/exportqes | - | Flag used to request an export to an Askia survey export in QES file format |
/exportinverted | - | Flag used to request an export to an Askia survey export in inverted format |
/exportfield | - | Flag used to request an export to an Askia field survey (SQL format) through the CcaWebAPI |
/targeturl | String | CcaWebAPI URL to use when exporting an Askia survey to field |
/targetusername | String | Supervisor's user name used to connect the CcaWebAPI when exporting an Askia survey to field |
/targetpassword | String | Supervisor's password used to connect the CcaWebAPI when exporting an Askia survey to field |
Example 1 : export to Askia survey in QES format.
Tools.exe "C:\Qes\Me\ExportData\ex.qes" /exportqes /completes /datafile:"C:\Qes\Me\ExportData\ExportDataRes.qes" /questionselection:"(CurrentQuestion.Tags Has {\"Demog\";\"LifeStyle\"} or CurrentQuestion.Type = \"open\") And (CurrentQuestion.IsAnonymised = False)" /additionalfilter:"i1_Gender = 1"
Example 2 : export to Askia survey in inverted format.
Tools.exe "C:\Qes\Me\ExportData\ex.qes" /exportinverted /completes /datafile:"C:\Qes\Me\ExportData\ExportDataInv.qex" /additionalfilter:"i1_Gender = 1"
Example 3 : export to Askia field survey.
Tools.exe "C:\Qes\Me\ExportData\ex.qes" /exportfield /targetUrl:"http://127.0.0.1/ccawebapi" /targetUserName:"Administrator" /targetPassword:”pwd" /completes /datafile:"NewExport" /additionalfilter:"i1_Gender = 1"
SAV export new options
We have added an option to specify which number you want the DK for closed questions exported as.
You can chose how the shortcuts of multiple closed questions will be post-fixed. Either using the modalities order, the modalities entry codes or with the same size entry codes.
We have added the options of the SAV Export so you can decide if you want to use the default current behaviour (use the flag that indicates a question is ranked), or if we always use dichotomy or export as if the question was a ranking.
The values (factors) of scaled responses can now be exported.
And all these options are accessible through command lines:
Parameter | Type | Description |
/preservecase | Integer | Indicates that the shortcuts case should be kept when exporting to SAV format. |
/samesizeloopentrycode | Integer | Flag indicating that loop items entry codes should have the same size. (possible values 0 or 1, default 0) |
/uselongcaption | Integer | Flag use to make sure long captions will be used in the SAV export. (possible values 0 or 1, default 0) |
/multipleseparator | String | A string to specify the separator of multiple closed questions. |
/entrycodeformultiple | Integer | Flag used to create multiple shortcut with entry codes. (possible values 0 or 1, default 0) |
/opensize | Integer | Value that specifies the size of open ended questions (default value : 1024, 1 for auto-detection). |
/numericdk | String | String to indicate if a numeric value should be interpreted as a system DK (used by /importpkd, /importdimensions and /exportsav) |
/closeddk | Integer | Parameter indicating the value of DK for closed questions. |
/shortcutpostfixtype | Integer | Value indicating how the shortcut of multiple closed questions should be postfixed. 0 : postfix with order 1 : postfix with entry codes 2 : postfix with same size entry codes |
/multipletype | Integer | Value indicating which format should be used to export multiple closed questions. 0 : use question ranking flag (check if the question is ranked - default behaviour) 1 : always use dichotomy 2 : always use ranking (export with the full list of resonses as a ranking) |
/usefactors | Integer | Flag use to indicate that values (factors) of scaled responses should be exported. (possible values 0 or 1, default 0) |
Verification script improvements
We have allowed to run verification scripts which can change interview data.
Once you have checked that you have allowed write back to the masque, you can use the Question.SetValue method and a new method (just for here) Interview.MarkAsCompleted( true / false).
All these calls are logged and you can see it in your list of Assert windows.
This option can be set as a default.
And accessible via command line with the parameter /allowwrite.
We have added an option to indicate where to look for a list of .ASX files to be used as a library of functions for the verification script.