Created
April 26, 2016 13:21
-
-
Save thomasaarholt/e4f921ea4ebb586a4777c02c07ad6655 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import hyperspy.api as hs | |
s = hs.load("MO") | |
# Get peak energy | |
Zr_Peak = 330. | |
O_peak = 532. | |
# Create signals with enough background and signal length to fit the components. | |
s_Zr = s.isig[Zr_Peak - 40.:Zr_Peak + 60.] | |
s_O = s.isig[O_peak - 40.:O_peak + 60.] | |
# Remove background | |
s_O2 = s_O.remove_background(signal_range=(395, 525.), background_type="PowerLaw", estimate_background=False) | |
s_Zr = s_Zr.remove_background(signal_range=(290.,320.), background_type="PowerLaw", estimate_background=False) | |
s_O2.plot() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment