Skip to content

Commit cb1425e

Browse files
authored
Merge pull request #11 from ajdapretnar/doc-scoring-sheet
[DOC] Scoring Sheet Viewer
2 parents 5cae678 + da5affa commit cb1425e

File tree

6 files changed

+90
-7
lines changed

6 files changed

+90
-7
lines changed
251 KB
Loading
88.1 KB
Loading
-21.4 KB
Binary file not shown.
-111 KB
Binary file not shown.

source/widgets/visualize/scoringsheetviewer.md

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,20 +9,25 @@ A widget for visualizing the scoring sheet predictions.
99

1010
**Outputs**
1111

12-
- Features: features used in the scoring sheet
12+
- Features: selected features used in the scoring sheet
1313

14-
![](images/ScoringSheetViewer-widget.png)
14+
**Scoring Sheet Viewer** widget offers a simple and intuitive way of visualizing the predictions of the scoring sheet model. The widget takes as input a trained scoring sheet model and an optional dataset (instance) on which we want to visualize the predictions. The widget presents us with a table that visualizes each feature's contribution to the final score, where a higher score indicates a greater chance for an instance to be classified with the target class. Each feature's contribution can be positive or negative, indicating whether it increases or decreases the risk.
1515

16-
**Scoring Sheet Viewer** widget offers a simple and intuitive way of visualizing the predictions of the scoring sheet model. The widget takes as input a trained scoring sheet model and a optional dataset (instance) on which we want to visualize the predictions. The widget presents us with a table that visualizes each feature's contribution to the final score, where a higher score indicates a greater chance for an individual to be classified with the target class. Each feature's contribution can be positive or negative, indicating whether it increases or decreases the risk.
16+
![](images/ScoringSheetViewer-stamped.png){width=400px}
1717

18+
1. *Target class*: set the target class for viewing.
19+
2. Scoring sheet with attributed points and an indicating, whether the attributes are selected for the output.
20+
3. Total scores and probabilities for a given instance.
21+
22+
The widget output selected features, which can be used downstream in [Scatter Plot](../visualize/scatterplot.md) or [Sieve Diagram](../visualize/sievediagram.md).
1823

1924
Example
2025
-------
2126

22-
![](images/ScoringSheetViewer-workflow.png)
27+
In this example, we first sample the *heart_disease* data, with 70% used to train the [Scoring Sheet](../model/scoringsheet.md) model and 30% routed to the [Data Table](../data/datatable.md) widget. This setup allows us to select instances and observe how the scoring sheet performs on new, unseen data.
2328

24-
In this example, we first sample the data, with a portion used to train the Scoring Sheet model and a part routed to the Table widget. This setup allows us to select instances and observe how the scoring sheet performs with new, unseen data.
29+
![](images/ScoringSheetViewer-Example.png)
2530

26-
Let's analyze and learn to interpret the scoring sheet using the example. It features five decision parameters, with points ranging from -5 to 5. We have set the target class to '1,' indicating the 'presence' of heart disease. Positive-value decision parameters increase the risk of heart disease, while those with negative values reduce it.
31+
Let's analyze and learn to interpret the scoring sheet using the example. It features five decision parameters, with points ranging from -5 to 5. We have set the target class to '1', indicating the 'presence' of heart disease. Positive-value decision parameters increase the risk of heart disease (i.e. reversable defect and asymptomatic chest pain), while those with negative values reduce it (i.e. ST by exercise higher than 1, no exercise induced angina, and few major vessels colored).
2732

28-
Consider a selected instance from the Data Table widget. It has a 'slope peak exc ST' attribute value of 'upsloping', which reduces the heart disease risk by 3 points. However, it also has the 'chest pain' attribute set to 'asymptomatic', increasing the risk by 5 points. This combination results in a total score of 2, corresponding to a 71.6% probability of having heart disease.
33+
Consider a selected instance from the Data Table widget. It has a 'exerc ind ang' attribute value of '0', which reduces the heart disease risk by 3 points. However, it also has the 'chest pain' attribute set to 'asymptomatic', increasing the risk by 4 points. This combination results in a total score of 2, corresponding to a 79.6% probability of having heart disease.
Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
<?xml version='1.0' encoding='utf-8'?>
2+
<scheme version="2.0" title="" description="">
3+
<nodes>
4+
<node id="0" name="File" qualified_name="Orange.widgets.data.owfile.OWFile" project_name="Orange3" version="" title="File" position="(86.0, 93.0)" />
5+
<node id="1" name="Data Sampler" qualified_name="Orange.widgets.data.owdatasampler.OWDataSampler" project_name="Orange3" version="" title="Data Sampler" position="(213.0, 93.0)" />
6+
<node id="2" name="Scoring Sheet" qualified_name="Orange.widgets.model.owscoringsheet.OWScoringSheet" project_name="Orange3" version="" title="Scoring Sheet" position="(376.0, 85.0)" />
7+
<node id="3" name="Data Table" qualified_name="Orange.widgets.data.owtable.OWTable" project_name="Orange3" version="" title="Data Table" position="(376.0, 193.0)" />
8+
<node id="4" name="Scoring Sheet Viewer" qualified_name="Orange.widgets.visualize.owscoringsheetviewer.OWScoringSheetViewer" project_name="Orange3" version="" title="Scoring Sheet Viewer" position="(545.0, 94.0)" />
9+
</nodes>
10+
<links>
11+
<link id="0" source_node_id="0" sink_node_id="1" source_channel="Data" sink_channel="Data" enabled="true" source_channel_id="data" sink_channel_id="data" />
12+
<link id="1" source_node_id="1" sink_node_id="2" source_channel="Data Sample" sink_channel="Data" enabled="true" source_channel_id="data_sample" sink_channel_id="data" />
13+
<link id="2" source_node_id="1" sink_node_id="3" source_channel="Remaining Data" sink_channel="Data" enabled="true" source_channel_id="remaining_data" sink_channel_id="data" />
14+
<link id="3" source_node_id="2" sink_node_id="4" source_channel="Model" sink_channel="Classifier" enabled="true" source_channel_id="model" sink_channel_id="classifier" />
15+
<link id="4" source_node_id="3" sink_node_id="4" source_channel="Selected Data" sink_channel="Data" enabled="true" source_channel_id="selected_data" sink_channel_id="data" />
16+
</links>
17+
<annotations />
18+
<thumbnail />
19+
<node_properties>
20+
<properties node_id="0" format="pickle">gASVqQoAAAAAAAB9lCiMEmNvbnRyb2xBcmVhVmlzaWJsZZSIjAxyZWNlbnRfcGF0aHOUXZQojB5v
21+
cmFuZ2V3aWRnZXQudXRpbHMuZmlsZWRpYWxvZ3OUjApSZWNlbnRQYXRolJOUKYGUfZQojAdhYnNw
22+
YXRolIw8L1VzZXJzL2FqZGEvb3JhbmdlL29yYW5nZTMvT3JhbmdlL2RhdGFzZXRzL2hlYXJ0X2Rp
23+
c2Vhc2UudGFilIwGcHJlZml4lIwPc2FtcGxlLWRhdGFzZXRzlIwHcmVscGF0aJSMEWhlYXJ0X2Rp
24+
c2Vhc2UudGFilIwFdGl0bGWUjACUjAVzaGVldJRoEIwLZmlsZV9mb3JtYXSUTnViaAYpgZR9lCho
25+
CYw2L1VzZXJzL2F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ZQojARpcmlzlGhHSwGMLElyaXMtc2V0b3NhLCBJcmlzLXZlcnNpY29sb3IsIElyaXMtdmly
66+
Z2luaWNhlIllZXNoMUsBdWhoKGjQSwKGlGjSSwKGlGjUSwKGlGjWSwKGlHSUaI8paJBo2F2UKIwL
67+
SXJpcy1zZXRvc2GUjA9JcmlzLXZlcnNpY29sb3KUjA5JcmlzLXZpcmdpbmljYZRlhpSFlGiUXZR1
68+
YmV1Lg==
69+
</properties>
70+
<properties node_id="1" format="literal">{'compatibility_mode': False, 'controlAreaVisible': True, 'number_of_folds': 10, 'replacement': False, 'sampleSizeNumber': 1, 'sampleSizePercentage': 70, 'sampleSizeSqlPercentage': 0.1, 'sampleSizeSqlTime': 1, 'sampling_type': 0, 'savedWidgetGeometry': None, 'selectedFold': 1, 'sql_dl': False, 'stratify': False, 'use_seed': True, '__version__': 2}</properties>
71+
<properties node_id="2" format="literal">{'auto_apply': True, 'controlAreaVisible': True, 'custom_features_checkbox': False, 'learner_name': '', 'max_points_per_param': 5, 'num_attr_after_selection': 20, 'num_decision_params': 5, 'num_input_features': 1, 'savedWidgetGeometry': b'\x01\xd9\xd0\xcb\x00\x03\x00\x00\x00\x00\x02:\x00\x00\x01/\x00\x00\x03\x9a\x00\x00\x02\x99\x00\x00\x02:\x00\x00\x01K\x00\x00\x03\x9a\x00\x00\x02\x99\x00\x00\x00\x00\x02\x00\x00\x00\x05\xe8\x00\x00\x02:\x00\x00\x01K\x00\x00\x03\x9a\x00\x00\x02\x99', '__version__': 1}</properties>
72+
<properties node_id="3" format="literal">{'auto_commit': True, 'color_by_class': True, 'controlAreaVisible': False, 'savedWidgetGeometry': b'\x01\xd9\xd0\xcb\x00\x03\x00\x00\x00\x00\x00&amp;\x00\x00\x01d\x00\x00\x02u\x00\x00\x02A\x00\x00\x00&amp;\x00\x00\x01\x80\x00\x00\x02u\x00\x00\x02A\x00\x00\x00\x00\x00\x00\x00\x00\x05\xe8\x00\x00\x00&amp;\x00\x00\x01\x80\x00\x00\x02u\x00\x00\x02A', 'select_rows': True, 'show_attribute_labels': True, 'show_distributions': False, 'stored_selection': {'rows': [0], 'columns': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]}, 'stored_sort': [], '__version__': 1}</properties>
73+
<properties node_id="4" format="literal">{'controlAreaVisible': True, 'savedWidgetGeometry': b'\x01\xd9\xd0\xcb\x00\x03\x00\x00\x00\x00\x02\x87\x00\x00\x01\x06\x00\x00\x04g\x00\x00\x02\x9d\x00\x00\x02\x87\x00\x00\x01"\x00\x00\x04g\x00\x00\x02\x9d\x00\x00\x00\x00\x00\x00\x00\x00\x05\xe8\x00\x00\x02\x87\x00\x00\x01"\x00\x00\x04g\x00\x00\x02\x9d', '__version__': 1}</properties>
74+
</node_properties>
75+
<session_state>
76+
<window_groups />
77+
</session_state>
78+
</scheme>

0 commit comments

Comments
 (0)