Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # -*- coding: utf-8 -*-
- """
- Created on Wed Oct 5 12:17:49 2016
- @author: Erbil ŞİLİk
- """
- # -*- coding: utf-8 -*-
- from glob import glob
- import numpy as np
- import matplotlib.pyplot as plt
- import matplotlib as mpl
- # loop over all files in the current directory ending with .txt
- for fname in glob("./*.txt"):
- # read file, skip header (1 line) and unpack into 3 variables
- POS, ESD = np.genfromtxt(fname, unpack=True)
- plt.tick_params(
- axis='both', which='both',
- right='off', left='off',
- top = 'off', bottom = 'off',
- labelleft='off')
- plt.plot(POS, ESD, color='blue')
- plt.xlabel('2${\Theta}$ (degree)')
- plt.ylabel('Intensity (a.u)')
- mpl.rcParams.update({'font.size': 12})
- #plt.legend(loc='lower center')
- # plt.title('')
- plt.show()
- #plt.savefig(fname + 't.tif', dpi=600)
- plt.clf()
- # x -> 2theta (degree)
- # y- > Intensity (a.u)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement