Get list of all entered house hold members (previously entered in a repeat group)

Hi ODK Community,

With new ODK release there was much talk about "Data Preloading"
possibilities. I am designing a survey that requires enumerator to select a
previously entered house hold member (entered as a repeat group) and then
answer additional questions related to him/her.

Is this possible with new ODK changes?

Regards,
Ayub

Ayub,

If you load that data into a CSV and then add it to form, then yes,
you can select that person and enter data about them.
http://opendatakit.org/help/form-design/data-preloading has
instructions.

Yaw

··· -- Need ODK services? http://nafundi.com provides form design, server setup, professional support, and software development for ODK.

On Fri, Aug 15, 2014 at 2:19 AM, Ayub nrspaggregate@gmail.com wrote:

Hi ODK Community,

With new ODK release there was much talk about "Data Preloading"
possibilities. I am designing a survey that requires enumerator to select a
previously entered house hold member (entered as a repeat group) and then
answer additional questions related to him/her.

Is this possible with new ODK changes?

Regards,
Ayub

--

Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Thanks for the reply Yaw,

I understand the referencing/searching through CSV file, but can i select a
household member entered earlier (as repeat group loop) in the same form,
during later/subsequent questions?

··· On Friday, August 15, 2014 6:58:34 PM UTC+5, Yaw Anokwa wrote: > > Ayub, > > If you load that data into a CSV and then add it to form, then yes, > you can select that person and enter data about them. > http://opendatakit.org/help/form-design/data-preloading has > instructions. > > Yaw > -- > Need ODK services? http://nafundi.com provides form design, server > setup, professional support, and software development for ODK. > > On Fri, Aug 15, 2014 at 2:19 AM, Ayub <nrspag...@gmail.com > wrote: > > Hi ODK Community, > > > > With new ODK release there was much talk about "Data Preloading" > > possibilities. I am designing a survey that requires enumerator to > select a > > previously entered house hold member (entered as a repeat group) and > then > > answer additional questions related to him/her. > > > > Is this possible with new ODK changes? > > > > Regards, > > Ayub > > > > -- > > -- > > Post: opend...@googlegroups.com > > Unsubscribe: opendatakit...@googlegroups.com > > Options: http://groups.google.com/group/opendatakit?hl=en > > > > --- > > You received this message because you are subscribed to the Google > Groups > > "ODK Community" group. > > To unsubscribe from this group and stop receiving emails from it, send > an > > email to opendatakit...@googlegroups.com . > > For more options, visit https://groups.google.com/d/optout. >

Yaw, I have gone through
http://opendatakit.org/help/form-design/data-preloading
http://www.google.com/url?q=http%3A%2F%2Fopendatakit.org%2Fhelp%2Fform-design%2Fdata-preloading&sa=D&sntz=1&usg=AFQjCNHNNfdnGwK7PjpIj3TS1qiZ3_OyXw and
not been able to find a solution :frowning:

Can I :

  1. Load/insert repeat-group data into CSV file* at runtime* during survey?
    (e.g. putdata() or similar function ... compared to pulldata()).

OR as earlier posted:

  1. One by one/conditional reference to repeat-group household member by
    using certain syntax.

Since that's core requirement of the survey, I would really appreciate your
input on this.

Regards,
Ayub

··· On Friday, August 15, 2014 6:58:34 PM UTC+5, Yaw Anokwa wrote: > > Ayub, > > If you load that data into a CSV and then add it to form, then yes, > you can select that person and enter data about them. > http://opendatakit.org/help/form-design/data-preloading has > instructions. > > Yaw > -- > Need ODK services? http://nafundi.com provides form design, server > setup, professional support, and software development for ODK. > > On Fri, Aug 15, 2014 at 2:19 AM, Ayub <nrspag...@gmail.com > wrote: > > Hi ODK Community, > > > > With new ODK release there was much talk about "Data Preloading" > > possibilities. I am designing a survey that requires enumerator to > select a > > previously entered house hold member (entered as a repeat group) and > then > > answer additional questions related to him/her. > > > > Is this possible with new ODK changes? > > > > Regards, > > Ayub > > > > -- > > -- > > Post: opend...@googlegroups.com > > Unsubscribe: opendatakit...@googlegroups.com > > Options: http://groups.google.com/group/opendatakit?hl=en > > > > --- > > You received this message because you are subscribed to the Google > Groups > > "ODK Community" group. > > To unsubscribe from this group and stop receiving emails from it, send > an > > email to opendatakit...@googlegroups.com . > > For more options, visit https://groups.google.com/d/optout. >

Hi Ayub,

Yes, you can identify elements entered in a repeat at a later point
using indexed-repeat().
http://opendatakit.org/help/form-design/binding/ has the syntax.

If you are trying to get at those values while inside the repeat (or
with filters), you'll have to use relative accessing.
https://groups.google.com/forum/#!msg/opendatakit/PVHE-WWrzvY/meWJSjbb9n0J
has a quick overview of what caveats are.

Strongly recommend you try this with a very small form first. Lots of
gotchas with indexed-repeat() and current() and I'm not an expert on
what all those gotchas are...

Yaw

··· -- Need ODK services? http://nafundi.com provides form design, server setup, professional support, and software development for ODK.

On Sun, Aug 17, 2014 at 8:33 AM, Ayub nrspaggregate@gmail.com wrote:

Yaw, I have gone through
http://opendatakit.org/help/form-design/data-preloading and not been able to
find a solution :frowning:

Can I :

  1. Load/insert repeat-group data into CSV file at runtime during survey?
    (e.g. putdata() or similar function ... compared to pulldata()).

OR as earlier posted:

  1. One by one/conditional reference to repeat-group household member by
    using certain syntax.

Since that's core requirement of the survey, I would really appreciate your
input on this.

Regards,
Ayub

On Friday, August 15, 2014 6:58:34 PM UTC+5, Yaw Anokwa wrote:

Ayub,

If you load that data into a CSV and then add it to form, then yes,
you can select that person and enter data about them.
http://opendatakit.org/help/form-design/data-preloading has
instructions.

Yaw

Need ODK services? http://nafundi.com provides form design, server
setup, professional support, and software development for ODK.

On Fri, Aug 15, 2014 at 2:19 AM, Ayub nrspag...@gmail.com wrote:

Hi ODK Community,

With new ODK release there was much talk about "Data Preloading"
possibilities. I am designing a survey that requires enumerator to
select a
previously entered house hold member (entered as a repeat group) and
then
answer additional questions related to him/her.

Is this possible with new ODK changes?

Regards,
Ayub

--

Post: opend...@googlegroups.com
Unsubscribe: opendatakit...@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google
Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send
an
email to opendatakit...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--

Post: opendatakit@googlegroups.com
Unsubscribe: opendatakit+unsubscribe@googlegroups.com
Options: http://groups.google.com/group/opendatakit?hl=en


You received this message because you are subscribed to the Google Groups
"ODK Community" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to opendatakit+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Hi Ayub,
I hope this example can help you.

Koassi

Get_list_of_all_entered_house_hold_members.xls (67 KB)

··· Le dimanche 17 août 2014 15:33:17 UTC, Ayub a écrit : > > Yaw, I have gone through > http://opendatakit.org/help/form-design/data-preloading > and > not been able to find a solution :( > > Can I : > > 1) Load/insert repeat-group data into CSV file* at runtime* during > survey? (e.g. putdata() or similar function ... compared to pulldata()). > > OR as earlier posted: > > > 2) One by one/conditional reference to repeat-group household member by > using certain syntax. > > Since that's core requirement of the survey, I would really appreciate > your input on this. > > Regards, > Ayub > > On Friday, August 15, 2014 6:58:34 PM UTC+5, Yaw Anokwa wrote: >> >> Ayub, >> >> If you load that data into a CSV and then add it to form, then yes, >> you can select that person and enter data about them. >> http://opendatakit.org/help/form-design/data-preloading has >> instructions. >> >> Yaw >> -- >> Need ODK services? http://nafundi.com provides form design, server >> setup, professional support, and software development for ODK. >> >> On Fri, Aug 15, 2014 at 2:19 AM, Ayub wrote: >> > Hi ODK Community, >> > >> > With new ODK release there was much talk about "Data Preloading" >> > possibilities. I am designing a survey that requires enumerator to >> select a >> > previously entered house hold member (entered as a repeat group) and >> then >> > answer additional questions related to him/her. >> > >> > Is this possible with new ODK changes? >> > >> > Regards, >> > Ayub >> > >> > -- >> > -- >> > Post: opend...@googlegroups.com >> > Unsubscribe: opendatakit...@googlegroups.com >> > Options: http://groups.google.com/group/opendatakit?hl=en >> > >> > --- >> > You received this message because you are subscribed to the Google >> Groups >> > "ODK Community" group. >> > To unsubscribe from this group and stop receiving emails from it, send >> an >> > email to opendatakit...@googlegroups.com. >> > For more options, visit https://groups.google.com/d/optout. >> >

I tried out a small form with indexed-repeat() and after lots of ODK
Collect crashes, errors, troubleshooting i got it to work. I have some
follow up questions on this:

  1. Can we possibly and more dynamically refer to a repeat group member
    since we have to create e.g. 10 static instances/variables/columns (hence
    restricting user response) ...
static_instance-nam-1 2 2
  1. How can we set dynamic value ('name') for an item that we get through
    indexed-repeat() ... I tried with:

But this crashed ODK Collect, is that because are defined in
separate instance than /data/hh9name and we can't reference values from
outside current instance?

I have attached the form which is exactly similar to Koassi AKAKPO's reply.

Regards,
Ayub

test.xml (6.48 KB)

··· On Monday, August 18, 2014 1:10:29 AM UTC+5, Yaw Anokwa wrote: > > Hi Ayub, > > Yes, you can identify elements entered in a repeat at a later point > using indexed-repeat(). > http://opendatakit.org/help/form-design/binding/ has the syntax. > > If you are trying to get at those values while inside the repeat (or > with filters), you'll have to use relative accessing. > https://groups.google.com/forum/#!msg/opendatakit/PVHE-WWrzvY/meWJSjbb9n0J > has a quick overview of what caveats are. > > Strongly recommend you try this with a very small form first. Lots of > gotchas with indexed-repeat() and current() and I'm not an expert on > what all those gotchas are... > > Yaw > -- > Need ODK services? http://nafundi.com provides form design, server > setup, professional support, and software development for ODK. > > On Sun, Aug 17, 2014 at 8:33 AM, Ayub <nrspag...@gmail.com > wrote: > > Yaw, I have gone through > > http://opendatakit.org/help/form-design/data-preloading and not been > able to > > find a solution :( > > > > Can I : > > > > 1) Load/insert repeat-group data into CSV file at runtime during survey? > > (e.g. putdata() or similar function ... compared to pulldata()). > > > > OR as earlier posted: > > > > > > 2) One by one/conditional reference to repeat-group household member by > > using certain syntax. > > > > Since that's core requirement of the survey, I would really appreciate > your > > input on this. > > > > Regards, > > Ayub > > > > On Friday, August 15, 2014 6:58:34 PM UTC+5, Yaw Anokwa wrote: > >> > >> Ayub, > >> > >> If you load that data into a CSV and then add it to form, then yes, > >> you can select that person and enter data about them. > >> http://opendatakit.org/help/form-design/data-preloading has > >> instructions. > >> > >> Yaw > >> -- > >> Need ODK services? http://nafundi.com provides form design, server > >> setup, professional support, and software development for ODK. > >> > >> On Fri, Aug 15, 2014 at 2:19 AM, Ayub wrote: > >> > Hi ODK Community, > >> > > >> > With new ODK release there was much talk about "Data Preloading" > >> > possibilities. I am designing a survey that requires enumerator to > >> > select a > >> > previously entered house hold member (entered as a repeat group) and > >> > then > >> > answer additional questions related to him/her. > >> > > >> > Is this possible with new ODK changes? > >> > > >> > Regards, > >> > Ayub > >> > > >> > -- > >> > -- > >> > Post: opend...@googlegroups.com > >> > Unsubscribe: opendatakit...@googlegroups.com > >> > Options: http://groups.google.com/group/opendatakit?hl=en > >> > > >> > --- > >> > You received this message because you are subscribed to the Google > >> > Groups > >> > "ODK Community" group. > >> > To unsubscribe from this group and stop receiving emails from it, > send > >> > an > >> > email to opendatakit...@googlegroups.com. > >> > For more options, visit https://groups.google.com/d/optout. > > > > -- > > -- > > Post: opend...@googlegroups.com > > Unsubscribe: opendatakit...@googlegroups.com > > Options: http://groups.google.com/group/opendatakit?hl=en > > > > --- > > You received this message because you are subscribed to the Google > Groups > > "ODK Community" group. > > To unsubscribe from this group and stop receiving emails from it, send > an > > email to opendatakit...@googlegroups.com . > > For more options, visit https://groups.google.com/d/optout. >

Hi Koassi,

Thank you so much, this example was great help understanding
indexed-repeat(), i have some follow up questions (posted above), hope you
can add something to it.

Regards,
Ayub

··· On Monday, August 18, 2014 1:27:54 PM UTC+5, Koassi AKAKPO wrote: > > Hi Ayub, > I hope this example can help you. > > Koassi > > Le dimanche 17 août 2014 15:33:17 UTC, Ayub a écrit : >> >> Yaw, I have gone through >> http://opendatakit.org/help/form-design/data-preloading >> and >> not been able to find a solution :( >> >> Can I : >> >> 1) Load/insert repeat-group data into CSV file* at runtime* during >> survey? (e.g. putdata() or similar function ... compared to pulldata()). >> >> OR as earlier posted: >> >> >> 2) One by one/conditional reference to repeat-group household member by >> using certain syntax. >> >> Since that's core requirement of the survey, I would really appreciate >> your input on this. >> >> Regards, >> Ayub >> >> On Friday, August 15, 2014 6:58:34 PM UTC+5, Yaw Anokwa wrote: >>> >>> Ayub, >>> >>> If you load that data into a CSV and then add it to form, then yes, >>> you can select that person and enter data about them. >>> http://opendatakit.org/help/form-design/data-preloading has >>> instructions. >>> >>> Yaw >>> -- >>> Need ODK services? http://nafundi.com provides form design, server >>> setup, professional support, and software development for ODK. >>> >>> On Fri, Aug 15, 2014 at 2:19 AM, Ayub wrote: >>> > Hi ODK Community, >>> > >>> > With new ODK release there was much talk about "Data Preloading" >>> > possibilities. I am designing a survey that requires enumerator to >>> select a >>> > previously entered house hold member (entered as a repeat group) and >>> then >>> > answer additional questions related to him/her. >>> > >>> > Is this possible with new ODK changes? >>> > >>> > Regards, >>> > Ayub >>> > >>> > -- >>> > -- >>> > Post: opend...@googlegroups.com >>> > Unsubscribe: opendatakit...@googlegroups.com >>> > Options: http://groups.google.com/group/opendatakit?hl=en >>> > >>> > --- >>> > You received this message because you are subscribed to the Google >>> Groups >>> > "ODK Community" group. >>> > To unsubscribe from this group and stop receiving emails from it, send >>> an >>> > email to opendatakit...@googlegroups.com. >>> > For more options, visit https://groups.google.com/d/optout. >>> >>

Hi ODK Community,

I still had some follow up questions:

Is it possible to store Household members name inside static variables? (or
any other way around indexed-repeat, i am open to options) and this would:

Return some name instead of 1, 2, 3, 4, actually i would like to ask
questions in the form with member name rather than its code:

e.g. Q. What does 1 do?, it would be better if i could ask e.g. Q. What
does Jon Doe do?

Regards,
Ayub

Hi Ayub,

You can use jr:choice-name(value, 'field') function as bellow.

type name label calculation select_one hh hhnam Select name?
calculate hhnam1 Name label jr:choice-name(${hhnam}, '${hhnam}') select_one
job job What does ${hhnam1} do?
Regards,
Koassi

··· Le lundi 1 septembre 2014 10:49:53 UTC, Ayub a écrit : > > Hi ODK Community, > > I still had some follow up questions: > > Is it possible to store Household members name inside static variables? > (or any other way around indexed-repeat, i am open to options) and this > would: > > > > Return some name instead of 1, 2, 3, 4, actually i would like to ask > questions in the form with member name rather than its code: > > e.g. Q. What does 1 do?, it would be better if i could ask e.g. Q. What > does Jon Doe do? > > Regards, > Ayub >

Hi Koassi,

That was really helpful, since i never used *jr:choice-name(value,
'field') , *it took me a little while to get it.

This URL helped a lot as
well: https://groups.google.com/forum/#!topic/opendatakit/AHDaDbUkj8Q

Quote from Christopher's reply:

jr:choice-name(value, 'field'): Returns the label for a select_one or

select_multiple field choice (as in the calculate expression
"jr:choice-name(${selectonefield}, '${selectonefield}')" to return the
label for the currently-selected choice in the selectonefield field). For
select_multiple fields, you can combine with selected-at() to get the label
for individual selections (as in
"jr:choice-name(selected-at(${selectmultfield}, 0), '${selectmultfield}')"
to return the label for the first choice in the selectmultfield field).

Thanks,

Regards,
Ayub