Download Stack/Stack_2cb88e5f9ef910ee/code.py from AIHero123/ChartM3: direct link, hf CLI and curl.
- Browser
- Download file 726 Bytes
-
https://huggingface.co/datasets/AIHero123/ChartM3/resolve/main/Stack/Stack_2cb88e5f9ef910ee/code.py
- Command line
-
hf download hf://datasets/AIHero123/ChartM3/Stack/Stack_2cb88e5f9ef910ee/code.py
-
curl -L -o code.py https://huggingface.co/datasets/AIHero123/ChartM3/resolve/main/Stack/Stack_2cb88e5f9ef910ee/code.py
726 Bytes
| import matplotlib.pyplot as plt | |
| # Time Intervals | |
| time_intervals = ['T1', 'T2', 'T3', 'T4', 'T5'] | |
| # Concentrations in ppm | |
| carbon_dioxide = [200, 180, 150, 130, 100] | |
| water_vapor = [120, 110, 100, 90, 80] | |
| nitrogen_oxides = [30, 35, 40, 45, 50] | |
| sulfur_dioxide = [10, 8, 6, 4, 2] | |
| # Create stackplot | |
| plt.figure(figsize=(10,6)) | |
| plt.stackplot(time_intervals, carbon_dioxide, water_vapor, nitrogen_oxides, sulfur_dioxide, labels=['Carbon Dioxide','Water Vapor','Nitrogen Oxides','Sulfur Dioxide']) | |
| # Customize the plot | |
| plt.legend(loc='upper right') | |
| plt.title('Vibrant Flame Dynamics in Combustion Processes') | |
| plt.xlabel('Time Intervals') | |
| plt.ylabel('Concentrations (ppm)') | |
| # Show plot | |
| plt.tight_layout() | |
| plt.savefig("figure.png") |