Commit 47aa5669 authored by Joaquin Torres's avatar Joaquin Torres

y range 0-1 for metrics

parent f46141b5
...@@ -40,6 +40,9 @@ if __name__ == "__main__": ...@@ -40,6 +40,9 @@ if __name__ == "__main__":
# Plot boxplot for the current metric across all models # Plot boxplot for the current metric across all models
ax.boxplot(metric_data, labels=model_names) ax.boxplot(metric_data, labels=model_names)
ax.set_title(f'{metric_name} for {group}{method}') ax.set_title(f'{metric_name} for {group}{method}')
# Set y-axis limits for metrics that take values in the interval [0, 1]
if metric_name in ['F1', 'PREC', 'REC', 'ACC', 'AUROC', 'AUPRC']:
ax.set_ylim(0, 1)
plt.tight_layout() plt.tight_layout()
fig.savefig(f'./output_cv_metrics/distributions/{group}{method}.svg', format='svg', dpi=600) fig.savefig(f'./output_cv_metrics/distributions/{group}{method}.svg', format='svg', dpi=600)
plt.close(fig) # Close the figure to free up memory plt.close(fig) # Close the figure to free up memory
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment