Skip to content

Commit

Permalink
Update view.py
Browse files Browse the repository at this point in the history
fix pyopenms_viz figure access
  • Loading branch information
axelwalter authored Oct 18, 2024
1 parent 786a272 commit 7d4343a
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions src/view.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ def plot_bpc_tic() -> go.Figure:
show_plot=False,
grid=False,
)
fig = fig.fig
if st.session_state.view_bpc:
df = st.session_state.view_ms1.groupby("RT").max().reset_index()
df["type"] = "BPC"
Expand All @@ -100,7 +99,6 @@ def plot_bpc_tic() -> go.Figure:
show_plot=False,
grid=False,
)
fig = fig.fig
if st.session_state.view_eic:
df = st.session_state.view_ms1
target_value = st.session_state.view_eic_mz.strip().replace(",", ".")
Expand Down Expand Up @@ -129,7 +127,6 @@ def plot_bpc_tic() -> go.Figure:
show_plot=False,
grid=False,
)
fig = fig.fig
except ValueError:
st.error("Invalid m/z value for XIC provided. Please enter a valid number.")

Expand Down Expand Up @@ -159,7 +156,6 @@ def plot_ms_spectrum(df, title, bin_peaks, num_x_bins):
bin_peaks=bin_peaks,
num_x_bins=num_x_bins,
)
fig = fig.fig
fig.update_layout(
template="plotly_white", dragmode="select", plot_bgcolor="rgb(255,255,255)"
)
Expand Down Expand Up @@ -217,7 +213,6 @@ def view_peak_map():
height=650,
width=900,
)
peak_map_3D = peak_map_3D.fig
st.plotly_chart(peak_map_3D, use_container_width=True)


Expand Down

0 comments on commit 7d4343a

Please sign in to comment.