This file contains 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 numpy as np | |
import matplotlib.pyplot as plt | |
def ScatterToContour(x,y, bins=[10,10]): | |
''' | |
x is the x location of the points | |
y is the y location of the points | |
len(x) needs to equal len(y) | |
bins determins the refinement of the histogram and line edges. | |
All contour plot perameters (levels, ect.) are defined outside |
This file contains 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
'this still needs better testing, espcially to work with numpy' | |
'needs to work with degrees and radians' | |
def convert(x): | |
'x is a list, would like it to work with numpy' | |
ind = x>180 | |
for i,j in enumerate(ind): | |
if j: | |
l[i]-=360 | |
return x |
This file contains 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 matplotlib.pyplot as plt | |
import numpy as np #casue it rocks | |
# get random values to plot | |
#needs to be in radians from (-pi,pi) & (-pi/2, pi/2) | |
a = np.random.rand(100)*2*np.pi - np.pi | |
d = np.random.rand(100)*np.pi - np.pi/2 | |
#todo(make values astropy.cooridnates and use wrap_at(180*u.degree). Allows for more varriable data. | |
#make figure |
This file contains 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
% \documentclass[apj, iop]{emulateapj} | |
% use for a preview of the final version | |
\documentclass[manuscript]{aastex} | |
%[manuscript] = defualt, and how you submit | |
%[preprint] = one-column, single-spaced document | |
%[preprint2] = double-column, single-spaced document | |
\usepackage{graphicx}% Include figure files | |
\usepackage{color}%for preprints | |
\usepackage{hyperref} |
This file contains 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 numpy as np | |
#create random data | |
data1 = np.random.rand(10) | |
data2 = np.random.rand(10) | |
data3 = np.random.rand(10) | |
#stack data into one ojbect | |
data_list = np.dstack((data1, data2, data3)) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
OlderNewer