Question type - Equation/sl: Difference between revisions
From LimeSurvey Manual
(Created page with "<div class="simplebox">Opomba: Ta tip vprašanja je mogoč od verzije 1.92 dalje</div>") |
(Updating to match new version of source page) |
||
(18 intermediate revisions by 3 users not shown) | |||
Line 3: | Line 3: | ||
=Kratek opis= | =Kratek opis= | ||
<div style="display:none;"></div> | |||
}}</ | <onlyinclude>{{#ifeq:{{{transcludesection|short_description}}}|short_description|<div style="display:none;"></div> | ||
{{ | {{Hint|Text=Unlike all other question types, if an equation is hidden, it is still computed, its value being stored in the database.}} | ||
{{ | {{Hint|Text=Equation question type allow to assign a value to another Question. See how to [[ExpressionScript - Presentation#Using assignment operator|use assignment Operator]].}} | ||
{{Alert|No HTML tag can be saved in the database due to security concerns.}} | |||
<div class="mw-translate-fuzzy"> | |||
Ta tip vprašanja dovoljuje avtorju, da izdela enačbo (npr.: izračun ali prilagojeno poročilo) ter jo shrani v podatkovno bazo kot spremenljivko. Za enačbo lahku uporabite sintakso, ki jo podpirac [[Expression Manager/sl|Urejevalnik izrazov]]. V primeru, da upravljate s številčnimi vrednostmi morate uporabiti napredne nastavitve "Samo števila", kot je opisano. | |||
</div> | |||
You may find below an example on how to use this question type: | |||
<center>[[FIle:Equation q ex 01.png]]</center> | |||
{{QS:scale_export}} | <center>[[File:Equation q ex 02.png]]</center> | ||
'''Example:''' [[Media:Limesurvey_survey_BMIsample.lss.zip|Limesurvey_survey_BMIsample.lss.zip]]. | |||
<div style="display:none;"></div>}}</onlyinclude><div style="display:none;"></div> | |||
=Editing an equation= | |||
== Using dedicated setting== | |||
The best way to edit equation is to use dedicated setting : this allow using same equation for different languages, and to be sure than no HTML is integrated in equation. This allow you to show a complete sentence to user but save only the needed value in database : for example put {weightkg/tall} in equation setting and show “Your BMI is {self.NAOK}”. | |||
If you need Expression inside : you have to add the curly brace. | |||
== Using Question text== | |||
You can do edits via the HTML/WYSIWYG editor or from the HTML source: | |||
* Using the WYSIWYG editor: | |||
<center>[[File:Equation-01.png]]</center> | |||
*From the HTML source: | |||
<center>[[File:Equation-02.png]]</center> | |||
The edits in the source code are recommended when you wish to record in your response table a clean text or a clean numeric value. By editing the source, you can remove/delete any HTML code that can affect the storing process. | |||
<center>[[File:Equation-03.png]]</center> | |||
<div class="simplebox">[[File:help.png]] '''Hint:''' To check different HTML editors, please see the wiki section on the [[First_login_-_your_user_preferences#HTML_editor_mode|HTML editor mode]].</div> | |||
<div class="mw-translate-fuzzy"> | |||
=Glavne nastavitve= | |||
</div> | |||
{{QS:mandatory/sl}} | |||
{{QS:relevance/sl}} | |||
=Display= | |||
{{QS:Hidden/sl}} | |||
{{QS:CSS_Class}} | |||
{{QS:Printable_survey_relevance_help}} | |||
=Logic= | |||
{{QS:Equation}} | |||
=Other= | |||
{{QS:Page_break/sl}} | |||
{{QS:scale_export/sl}} | |||
{{QS:numbers_only/sl}} | |||
=Statistics= | |||
{{QS:Public_statistics/sl}} | |||
{{QS:Display_chart}} | |||
{{QS:Chart_type}} | |||
[[Category:Question types]][[Category:Mask questions]] |
Revision as of 18:30, 20 May 2020
Kratek opis
Ta tip vprašanja dovoljuje avtorju, da izdela enačbo (npr.: izračun ali prilagojeno poročilo) ter jo shrani v podatkovno bazo kot spremenljivko. Za enačbo lahku uporabite sintakso, ki jo podpirac Urejevalnik izrazov. V primeru, da upravljate s številčnimi vrednostmi morate uporabiti napredne nastavitve "Samo števila", kot je opisano.
You may find below an example on how to use this question type:
Example: Limesurvey_survey_BMIsample.lss.zip.
Editing an equation
Using dedicated setting
The best way to edit equation is to use dedicated setting : this allow using same equation for different languages, and to be sure than no HTML is integrated in equation. This allow you to show a complete sentence to user but save only the needed value in database : for example put {weightkg/tall} in equation setting and show “Your BMI is {self.NAOK}”.
If you need Expression inside : you have to add the curly brace.
Using Question text
You can do edits via the HTML/WYSIWYG editor or from the HTML source:
- Using the WYSIWYG editor:
- From the HTML source:
The edits in the source code are recommended when you wish to record in your response table a clean text or a clean numeric value. By editing the source, you can remove/delete any HTML code that can affect the storing process.
Glavne nastavitve
Obvezno
Opis
Ta možnost skrbnikom ankete omogoča, da od svojih anketirancev zahtevajo, da odgovorijo na določena anketna vprašanja. Če na obvezna vprašanja ne odgovorijo, anketiranci ne bodo mogli nadaljevati. Če imate vprašanje z več podvprašanji in zahtevate odgovor le na določena podvprašanja, uporabite atribut minimalni odgovor, ki se nahaja pod zavihkom Logika.
Razpoložljive možnosti
- Vklopljeno - na vprašanje je treba odgovoriti, preden lahko udeleženec nadaljuje na naslednjo stran - možnost odgovora 'Brez odgovora' ni nikoli prikazana.
- Soft - Če na vprašanje ni odgovorjeno, se ob poskusu nadaljevanja prikaže opozorilo naslednja stran - vendar se lahko udeleženec odloči, da opozorilo prezre in nadaljuje. Upoštevajte, da je možnost 'Brez odgovora' še vedno prikazana (če je aktivirana v nastavitvah predstavitve ankete)
- Izklopljeno (privzeto) - Vprašanje lahko ostane brez odgovora
Pogoj (prej "Enačba ustreznosti")
Opis
Če je rezultat pogoja »1« ali »true«, je vprašanje v kontekstu ankete »relevantno«, torej se prikaže anketirancu. Če ne, je vprašanje skrito. Vsako anketno vprašanje vam omogoča, da določite enačbo pomembnosti. Ta funkcija je naslednica pogojev in podpira veliko bolj zapleteno pogojno logiko.
Označevanje sintakse
Kadarkoli shranite pogoj, je ovrednoten in sintaktično poudarjen. Morebitne napake bodo označene z barvami, da jih boste lahko hitro odkrili in odpravili.
Veljavne vrednosti
- Kateri koli pogoj, ki uporablja sintakso ExpressionScript brez okoliških zavitih oklepajev.
Primeri
Tu so dobri primeri označevanja sintakse.
Display
Vedno skrij to vprašanje (skrito)
Opis
Če je omogočeno, bo vprašanje vedno skrito – ne bo prikazano udeležencem ankete. To funkcijo je mogoče uporabiti v naslednjih scenarijih:
- Če želite vprašanje vnaprej izpolniti z URL-jem in ne želite, da se prikaže na zaslonu. To preglasi vse pogoje, uporabljene v anketi, ker zadevno vprašanje sploh ne bo vdelano na stran.
- Če želite sproti shraniti ali izračunati vrednost prek ExpressionScript - Presentation.
'Razpoložljive možnosti
- Vklopljeno
- Izklopljeno (privzeto)
CSS class (css_class)
Description
If you want to add special CSS classes to certain questions, you can enter the CSS class name(s) in this box. Make sure you leave an empty space between different class names.
Valid values
- Any text string with a space between different CSS class names.
Relevance help for printable survey (printable_survey_relevance_help)
Description
If you wish to print a survey, you can also print the relevance equations for each question. But, if you wish to offer instead an explanation rather than the expression on the printed form, fill in this box with the text explanation for the relevance equation.
Valid values
- Any text and/or numbers you wish to be displayed on the printable form.
Logic
Equation (equation)
Description
The result of the expression you type here will be stored in the response table and NOT the result(s) of the expressions typed in the question textbox. For example, you may want to display several expressions in the question textbox to display the respondents some statistics about herself. However, if you wish to store something different at the same time, then type the desired expression in this field.
This equation is used for all language.
Valid values
- Any text. The Expression Manager syntax can also be used (with surrounding curly braces).
Other
Vstavi prelom strani v pogledu za tiskanje (page_break)
Opis
Ta atribut je aktiven le, ko dejansko natisnete anketo iz »Pogleda za tiskanje«. Vsili prelom strani pred vprašanjem.
Razpoložljive možnosti
- Vklopljeno
- Izklopljeno (privzeto)
Vrsta SPSS izvozne skale (scale_export)
Opis
To se uporablja samo za izvoz SPSS. Ta atribut preglasi privzeto lestvico, ki jo ugane SPSS. Če želite izvedeti, kaj počnejo različne merilne lestvice, preberite povezano dokumentacijo SPSS.
Razpoložljive možnosti
- Privzeto (privzeto)
- Nominalno
- Ordinalno
- Lestvica
Samo številke (samo številke)
Opis
Če omogočite to možnost, lahko udeleženec vnaša samo številke v besedilna polja.
Za vrste vprašanj z enačbo ta nastavitev nakazuje, da je lahko rezultat samo število, ne pa niz. To bo zagotovilo pravilne izračune/pretvorbe v nadaljnjih enačbah glede decimalne oznake.
Vedenje glede na vrsto vprašanja
- Privzeto: Če subjekt vnese vrednost, ki ni številka, se ta vrednost takoj počisti iz besedilnega polja, tako da subjekt lahko vnese ustrezno vrednost.
- Array (Texts): Če je možnost samo številke onemogočena, bosta možnosti "Prikaži vsote za" in "Prikaži skupno vsoto" preglasovani, medtem ko skupna besedilna polja ne bodo prikazana.
- Enačba: Če omogočite to možnost, bodo rezultati enačbe pretvorjeni v številsko vrednost. Če rezultat enačbe ni število (in ni prazno), bo enačba vrnila NaN in bo shranjena kot prazen niz v tabeli odgovorov.
'Razpoložljive možnosti
- Vklopljeno
- Izklopljeno (privzeto)
Statistics
Prikaži v javni statistiki (public_statistics)
Opis
Ta atribut omogoča administratorju ankete, da izbere, ali naj se rezultati določenega vprašanja prikažejo udeležencem ankete, potem ko so oddali anketo.
Privzeta nastavitev za vsako vprašanje je 'Izklopljeno' (=Ali ne anketirancem prikaži statistike vprašanj). To morate omogočiti za vsako posamezno vprašanje, če želite udeležencem ankete po oddaji ankete pokazati statistiko ankete za to (tista) določena vprašanja.
Razpoložljive možnosti
- Vklopljeno
- Izklopljeno (privzeto)
Display chart (display_chart)
Description
This attribute allows the survey administrator to choose if a chart that contains the question results should be displayed to the survey participants after they filled out the survey.
- public statistics survey setting from the presentation & navigation settings
- show graphs survey setting from the presentation & navigation settings
- public statistics question attribute, and
- display chart question attribute.
Available options
- On
- Off (default)
Chart type (chart_type)
Description
This attribute allows the survey administrator to choose which type of chart will be displayed to the respondent once he/she finished filling out the survey.
Available options
- Bar chart
- Pie chart
- Radar
- Line
- PolarArea
- Doughnut