// pick up the trial if we have selected a specific one if (!isset($_GET['trial'])) { $trial = 1; } if (isset($_GET['trial'])) { $trial = $_GET['trial']; } // pick up the participant if we have selected a specific one if (!isset($_GET['participant'])) { $participant = $participant_list[0]; } if (isset($_GET['participant'])) { $participant = $_GET['participant']; } // work out the trial list $trial_list = single_column_array_builder_groupby($current_project . "." . $participant . "_aggregated", "trial_index"); sort($trial_list, SORT_NUMERIC); // pick up the analyses if we have selected a specific one if (!isset($_GET['analyses'])) { $analyses = $analyses_list[0]; } if (isset($_GET['analyses'])) { $analyses = $_GET['analyses']; } // sort out the column list parse_str(urldecode($_SERVER['QUERY_STRING']), $data); $selected_column_list = $data['column_list']; $default_column_list = array('trial', 'CURRENT_FIX_INDEX', 'CURRENT_fIX_DURATION', 'value', 'response', 'rt', 'outcome'); if (is_array($selected_column_list)) { $column_list = array_merge($selected_column_list, $default_column_list); }
<?php include "../conf/conf.php"; include "../functions/table_builder.php"; include "../functions/single_column_array_builder.php"; include "../functions/header_array_builder.php"; include "../functions/option_list_builder.php"; include "../functions/trial_display.php"; if ($_GET['refresh'] == 'histogram_form') { // get the ppts and lsit them $participant_list = single_column_array_builder_groupby("" . $current_project . ".analyses_output", "ppt_id"); array_unshift($participant_list, 'all'); // set runner list $runner_list = single_column_array_builder_groupby("" . $current_project . ".analyses_output", "runner"); // options for number of bins $bin_list = array(); for ($i = 1; $i < 51; $i++) { $bin_list[] = $i; } // Start building the form now echo "<article id='participant_list_form' name='histogram_selection_form'>"; echo "<form>"; echo "Note: This section is a work in progress.<br>"; echo "Select Runner:"; option_list_builder('selected_runner', $runner_list, '', ''); echo "<br>"; echo "Select Participant:"; option_list_builder('selected_participant', $participant_list, '', ''); echo "<br>"; echo "Number of Bins:"; option_list_builder('selected_bincount', $bin_list, '', '20');