Spaces:
Sleeping
Sleeping
Update templates/output.html
Browse files- templates/output.html +47 -1
templates/output.html
CHANGED
|
@@ -141,7 +141,7 @@
|
|
| 141 |
</script> -->
|
| 142 |
|
| 143 |
<!-- Dot Chart with Markers -->
|
| 144 |
-
<script>
|
| 145 |
const chartData = {{ chart_data | safe }};
|
| 146 |
|
| 147 |
const trace1 = {
|
|
@@ -171,6 +171,52 @@
|
|
| 171 |
margin: { t: 40, l: 50, r: 30, b: 50 }
|
| 172 |
};
|
| 173 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 174 |
Plotly.newPlot('line-chart', [trace1, trace2], layout);
|
| 175 |
</script>
|
| 176 |
|
|
|
|
| 141 |
</script> -->
|
| 142 |
|
| 143 |
<!-- Dot Chart with Markers -->
|
| 144 |
+
<!-- <script>
|
| 145 |
const chartData = {{ chart_data | safe }};
|
| 146 |
|
| 147 |
const trace1 = {
|
|
|
|
| 171 |
margin: { t: 40, l: 50, r: 30, b: 50 }
|
| 172 |
};
|
| 173 |
|
| 174 |
+
Plotly.newPlot('line-chart', [trace1, trace2], layout);
|
| 175 |
+
</script> -->
|
| 176 |
+
|
| 177 |
+
<!-- Dot Chart Fixed View -->
|
| 178 |
+
<script>
|
| 179 |
+
const chartData = {{ chart_data | safe }};
|
| 180 |
+
|
| 181 |
+
const trace1 = {
|
| 182 |
+
x: chartData.EngCts,
|
| 183 |
+
y: chartData.Makable_Predicted,
|
| 184 |
+
type: 'scatter',
|
| 185 |
+
mode: 'markers',
|
| 186 |
+
name: 'Makable_Predicted',
|
| 187 |
+
marker: { color: '#00BFFF', size: 8 }
|
| 188 |
+
};
|
| 189 |
+
|
| 190 |
+
const trace2 = {
|
| 191 |
+
x: chartData.EngCts,
|
| 192 |
+
y: chartData.Makable_Diff,
|
| 193 |
+
type: 'scatter',
|
| 194 |
+
mode: 'markers',
|
| 195 |
+
name: 'Makable_Diff',
|
| 196 |
+
marker: { color: '#FF6347', size: 8 }
|
| 197 |
+
};
|
| 198 |
+
|
| 199 |
+
const layout = {
|
| 200 |
+
paper_bgcolor: "#04293A",
|
| 201 |
+
plot_bgcolor: "#041C32",
|
| 202 |
+
font: { color: "#ECB365" },
|
| 203 |
+
xaxis: {
|
| 204 |
+
title: "EngCts",
|
| 205 |
+
tickangle: 0
|
| 206 |
+
},
|
| 207 |
+
yaxis: {
|
| 208 |
+
title: "Values",
|
| 209 |
+
tickfont: {
|
| 210 |
+
size: 10,
|
| 211 |
+
color: "#ECB365"
|
| 212 |
+
},
|
| 213 |
+
automargin: true, // 🔧 Add space for long labels
|
| 214 |
+
tickmode: "auto", // Let Plotly auto-decide tick values
|
| 215 |
+
nticks: 10, // Reduce clutter
|
| 216 |
+
},
|
| 217 |
+
margin: { t: 40, l: 80, r: 30, b: 50 } // ⬅️ Increase left margin for Y-axis labels
|
| 218 |
+
};
|
| 219 |
+
|
| 220 |
Plotly.newPlot('line-chart', [trace1, trace2], layout);
|
| 221 |
</script>
|
| 222 |
|