Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F69924594
plot_galaxy_frequencies.py
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Thu, Jul 4, 05:52
Size
665 B
Mime Type
text/x-python
Expires
Sat, Jul 6, 05:52 (2 d)
Engine
blob
Format
Raw Data
Handle
18768801
Attached To
rPNBODY pNbody
plot_galaxy_frequencies.py
View Options
#!/usr/bin/env python
import
sys
import
Ptools
as
pt
from
numpy
import
*
from
pNbody
import
libmiyamoto
ltypes
=
[
"-"
,
"--"
,
":"
,
"o"
]
files
=
sys
.
argv
[
1
:]
fig
=
pt
.
figure
()
pt
.
subplot
(
1
,
1
,
1
)
i
=
0
for
file
in
files
:
stats_d
=
pt
.
io
.
read_dmp
(
file
)
###################
# plot
###################
#r = stats_h['r']
R
=
stats_d
[
'R'
]
####################
# velocity curves
####################
pt
.
plot
(
R
,
stats_d
[
'kappa'
],
'r'
+
ltypes
[
i
])
pt
.
plot
(
R
,
stats_d
[
'omega'
],
'g'
+
ltypes
[
i
])
pt
.
plot
(
R
,
stats_d
[
'nu'
],
'b'
+
ltypes
[
i
])
i
=
i
+
1
pt
.
xlabel
(
'Radius'
)
pt
.
ylabel
(
'Velocity'
)
pt
.
legend
((
'kappa'
,
'omega'
,
'nu'
))
pt
.
show
()
Event Timeline
Log In to Comment