initialiseRoles function

void initialiseRoles(
  1. List<VariableInfo> vars,
  2. List<String> highVars,
  3. Map<String, Role> currentRoles,
  4. WidgetRef ref,
)

Implementation

void initialiseRoles(
  List<VariableInfo> vars,
  List<String> highVars,
  Map<String, Role> currentRoles,
  WidgetRef ref,
) {
  if (currentRoles.isEmpty && vars.isNotEmpty) {
    for (var column in vars) {
      _setInitialRole(column, ref);
    }
    _setTargetRole(vars, ref);
    _setIdentRole(ref);

    // 20241213 gjw Let's turn off the IGNORE heursitic for now. Leave it to a
    // user to decide. For the PROTEIN dataset we want COUNTRY to be IDENT r
    // TARGET rather than IGNORE.

    // _setIgnoreRoleForHighVars(highVars, ref);
  }
}