complex branching


Author
Message
nc
nc
nc
posted 4 Years Ago HOT
Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)Esteemed Member (2.4K reputation)
Group: Forum Members
Posts: 39, Visits: 108
Hi all, I'm trying to create complex branching where a certain block appears once the subject either (a) gives 2 incorrect responses on the first trial; (b) gives at least 2 correct answers on the first trial and at least 2 incorrect answers on the second trial; (c) gives at least 2 correct answers on the 2nd trial and at least 2 incorrect answers on the 3rd trial....and so on. Here is my code, and it's not working. Can anyone help me understand what I'm doing wrong?

<block test>
/trials = [1=one]
/branch = [
    if (trial.one.totalerrorcount >=2) block.end
]
/branch = [
     if (trial.one.totalcorrectcount >=2 && trial.two.totalerrorcount >=2) block.end
]
/branch = [
     if (trial.two.totalcorrectcount >=2 && trial.three.totalerrorcount >=2) block.end
]
/branch = [
     if (trial.three.totalcorrectcount >=2 && trial.four.totalerrorcount >=2) block.end
]
/branch = [
     if (trial.four.totalcorrectcount >=2 && trial.five.totalerrorcount >=2) block.end
]
/branch = [
     if (trial.five.totalcorrectcount >=2 && trial.six.totalerrorcount >=2) block.end
]
/branch = [
     if (trial.six.totalcorrectcount >=2) block.end
]
</block>
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Threaded View
Threaded View
nc - 4 Years Ago
nc - 4 Years Ago
Dave - 4 Years Ago
                 + x [quote] [b] Dave - 6/29/2020 [/b] + x...
nc - 4 Years Ago
nc - 4 Years Ago
                         > it seems like the expressions with && are the ones not being...
Dave - 4 Years Ago
                             the block doesn't end when there are 2 correct responses on trial...
nc - 4 Years Ago
                                 Please provide the full script including any and all external files it...
Dave - 4 Years Ago
                                     Assuming the /branch attributes in your <trial one> snippet you...
Dave - 4 Years Ago
                                     + x [quote] [b] Dave - 6/29/2020 [/b] + x...
nc - 4 Years Ago
                                         + x [quote] [b] nc - 6/29/2020 [/b] + x [quote]...
nc - 4 Years Ago
                                             Also to reply to a previous comment: the branching you pointed to is...
nc - 4 Years Ago
                                                 Thanks for the script. I asked you for some kind of description of how...
Dave - 4 Years Ago
                                                     I'm not sure what kind of description I should provide. It's meant to...
nc - 4 Years Ago
                                                         Sorry, I meant to say - if they get a number wrong, they go down a...
nc - 4 Years Ago
                                                             I see now you sent the script. Thank you SO much!! Works great
nc - 4 Years Ago

Reading This Topic

Explore
Messages
Mentions
Search