Skip to content

How to crop a spectrum? #60

Answered by georgievgeorgi
nicocopez asked this question in Q&A
Discussion options

You must be logged in to vote

Yes, we have such a method in RC2 -- trim_axes
One can specify boundaries in 'x-axis' units or 'bin' index via method parameter.

This example should do the same as yours (unless i have a typo):

low_end = 580
high_end = 600
spe_cr = spe.trim_axes(method='x-axis', boundaries=(low_end, high_end))
spe_cr.plot()

My original answer was as a reply to the second comment. I am posting it again so that it can be marked as an answer

Replies: 2 comments 2 replies

Comment options

nicocopez
Feb 28, 2023
Maintainer Author

You must be logged in to vote
2 replies
@georgievgeorgi
Comment options

@nicocopez
Comment options

nicocopez Feb 28, 2023
Maintainer Author

Comment options

You must be logged in to vote
0 replies
Answer selected by georgievgeorgi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants