## Observable Notebook Self-documentation
### Main Display Cells
- mainPageNested - Main display of matrix;
### Input Controls - Affecting Output Display
- obsSelType = group of occupations to process: Ref-200, Modulo-4 (0 or 2 for first, third), others (later)
- This controls the set of occupations processed by setting xxxxxyyyyzzz
- obsOccupSeq = occupation sequence: Major O*Net Group, OccO Onto Group, or Random
- This controls the sequence of occupations displayed horizontally
- Upon change the occupations are sorted by Onto Group (***FIELD??) and vertical line dividers between occup groups are set in obArOccupGrpIndices
- obsSkillSeq = O*Net sequence or Skill Onto Group
- This controls the vertical ordering of skills, with indices between skill groups in divHorSkillsONet and divHorSkillsOccO
### Input Data, and Related Array or Dictionary
- data_Occup; converted to dict_Occup
- Note: This also contains the 36-entry arrays for 36 im and lv values (entry zero unused)
- filename = O-Net B_Occupations SOC-Related (2021-06-10).csv
- data_SkillOccup; remains as read from .json file, array of objects
- filename = O-Net C_Skill-Occupation with Metrics (2021-06-10).csv
- data_Skills; converted to dict_Skills << Note: dict_Skills appears NOT to be used!
- filename = O-Net D_Skills_TreeOnto (2021-06-10).csv
### Derived Data: Processing Objects derived from Input
- obsArSelOccupIds: the MAIN ordered list of occupation ids in the desired sequence (ONet or Onto)
- obsArSkillsAndStats: Main reference for display of skills: skillId (from Element_ID in SkillOccup), ONetIdx (as-is), OntoIdx: Onto Seq and the average and standard distribution for each skill across all occupations.
- obsArOccupGrpIndices: currently dispayed occupation indices at which groups change for vertical dividers
- obsArSkillIdxOnto: array for each skill in ONTOLOGICAL order showing the ONetIdx (original, as-read) index for accessing skills table
### Output Entities that appear in Main Page
- obsMessage -- attempt to in effect put console log output on display; did this work out?
### Functions
- fnSkillsOccupAnalyze
- fnOccupAnalyze
- drag {} - object that contains several functions: dragstarted, draffed, dragended to handle the drag event
- use or get rid of: dictOccupSkills, obsStatsBySkill, fuCalcStatsBySkill, obsStatsByOccup, finCalcStatsByOccup
- *** OR: usee calc stats to do entropy!!
- fnCalcStatsBy
### Imports
- Tooltip from "@clhenrick/tooltip-component"
### Standard Notebook cells
- d3
- obscfg - configuration info (window size, margins, etc) plus app-specific constants:
- Skill level colors
- divHorSkillsONet - the indices at which skill group horizontal line appears in O*Net sequence change
- divHorSkillsOccO - same, when in OccO Onto skill sequence
Other?
### Coding Standards
- obscfg execution options for margin, height, width if not full
- obs prefix for an app variable – assumed to be an object not array
- obsAr Prefix for an app variable that is an array of values or objects
- data_ Prefix for data read in from JSON or CSV as array of objects
- dict_ Prefix for input data converted to a dictionary with key, value
- fn Prefix for a cell that is a function
- obsFn Prefix for a cell that is an object containing functions
- Example: drag has dragstarted, dragged, and dragend functions
- Avoid variable names that are identical to common library variables (eg. x, y, value, key)