Conversation
| ) | ||
| ax_i.fill_between( | ||
| x_i, | ||
| *pdf_set.get_uncertainties(observable=obs_i, Q=Q_i), |
There was a problem hiding this comment.
Hier Möglichkeit einfügen, zwischen uncertainty convention "asym" und "sym" zu wählen.
| kwargs_annotation: dict[str, Any] | list[dict[str, Any] | None] = {}, | ||
| kwargs_xlabel: dict[str, Any] = {}, | ||
| kwargs_ylabel: dict[str, Any] = {}, | ||
| kwargs_legend: dict[str, Any] = {}, |
There was a problem hiding this comment.
plus variable für uncertainty convention
| ax_i.plot( | ||
| x_i, | ||
| pdf_set.get_uncertainty("+", obs_i, Q=Q_i), | ||
| **kwargs, |
There was a problem hiding this comment.
hier dann ebenfallls uncertainty convention als Argumen übergeben
| # ... or as ylabel | ||
| elif pdf_label == "ylabel": | ||
| ax_i.set_ylabel( | ||
| f"${to_str(obs_i, Q=Q_i_label)}$", **kwargs_ylabel |
There was a problem hiding this comment.
Hier würde ich den text des y_labels auch in kwargs_y_label default packen und dem kwargs überschreiben arbeiten, sodass der Nutzer seine y-Achse mit beliebigem Text beschriften kann
| f"${to_str(obs_i, Q=Q_i_label)}$", **kwargs_ylabel | ||
| ) | ||
|
|
||
| ax_i.set_xlabel("$x$", **kwargs_xlabel) |
There was a problem hiding this comment.
Hier würde ich den text des x_labels auch in kwargs_x_label_default packen und dem kwargs überschreiben arbeiten, sodass der Nutzer seine y-Achse mit beliebigem Text beschriften kann, das kann zb praktisch sein, wenn man nur an einem vn vielen plots überhaupt ein label möchte. Und solange es in den default_kwargs ist, wird es ja trotzdem per default genauso gesetzt
| kwargs_annotation: dict[str, Any] = {}, | ||
| kwargs_xlabel: dict[str, Any] = {}, | ||
| kwargs_ylabel: dict[str, Any] = {}, | ||
| kwargs_legend: dict[str, Any] = {}, |
There was a problem hiding this comment.
Uncertainty convention hinzufügen
| ) | ||
| ax_i.fill_between( | ||
| x_i, | ||
| *pdf_set.get_uncertainties(observable=obs_i, Q=Q_i), |
There was a problem hiding this comment.
Uncertainty convention hinzufügen
| ) | ||
| ax_i.plot( | ||
| x_i, | ||
| pdf_set.get_uncertainty("+", obs_i, Q=Q_i), |
There was a problem hiding this comment.
Uncertainty convention
| ) | ||
| ax_i.plot( | ||
| x_i, | ||
| pdf_set.get_uncertainty("-", obs_i, Q=Q_i), |
There was a problem hiding this comment.
Uncertainty convention
| kwargs_annotation, | ||
| ) | ||
| ax_i.annotate( | ||
| f"${to_str(obs_i, Q=Q_i_label)}$", |
There was a problem hiding this comment.
text der annotation in default kwargs
| ) | ||
|
|
||
| else: | ||
| ax_i.set_xlabel("$x$", **kwargs_xlabel) |
There was a problem hiding this comment.
text des x-labels in default kwargs s.o.
|
|
||
| # add the ylabel | ||
| if pdf_label == "ylabel": | ||
| ax_i.set_ylabel( |
There was a problem hiding this comment.
text ylabel in default kwargs s.o.
| np.max( | ||
| [ | ||
| self.get(A=A_i).get_uncertainty("+", obs_i, x=x, Q=Q, Q2=Q2) | ||
| for A_i in A |
There was a problem hiding this comment.
Add uncertainty convention
| ) | ||
| l = ax_i.plot( | ||
| x_i, | ||
| pdf_set.get_central(obs_i, Q=Q_i), |
There was a problem hiding this comment.
Ich versteh nicht ganz wie hier (und überall sonst wo geplottet wird) das mit Q_i als array läuft. Ich denke das muss ein float sein an dieser Stelle.
There was a problem hiding this comment.
Habs getestet und in der Tat funktioniert es nur, wenn Q ein float ist
Add a function to plot the A-dependence of a
NuclearPDFSetin a pseudo-3D plot, i.e. using insets.