axesm

Hi, im trying to write an m-file that uses an axesm function. I am imaginging the sky in radiowaves and cannot get the function to work. It runs but errors when the graph show. Can anyone help? Thanks Luke axesm('hammer'); patchm (lat, long, 'f'); setm (gca,'Origin', [30 130 135]);

8 个评论

Walter Roberson
Walter Roberson 2011-2-8
Please expand upon what error you encounter.
Jan
Jan 2011-2-15
Please insert a copy of the error message in this question and use the code formatting.
Andrew Newell
Andrew Newell 2011-2-15
@Luke, please help us to help you! It would be easier to diagnose the problem if you provide some data for lat and long and tell us what the error message is.
Luke
Luke 2011-2-15
its not displaying an error anymore. Just running and loading the graph my code is now,
f=d-v;
r = srtdata1.ra;
dec = srtdata1.dec;
axesm('hammer','Grid','on','Frame','on');
patchm (lat, long, 'f');
setm (gca,'Origin', [30 130 ]);
I know im being a pain but im not used to using matlab, Thanks guys
Andrew Newell
Andrew Newell 2011-2-15
O.k., that's a start. Now what are the values of d, v, and srtdata1?
Luke
Luke 2011-2-15
d is the time, v is a polyval and srtdata1 is just the raw data
Andrew Newell
Andrew Newell 2011-2-15
Can you give me some actual numerical values for these data? Then tell me what you see when you run your code and what you want to see.
Luke
Luke 2011-2-15
there matrices and channels. Its data from the galactic plane so theres a lot of it. Thanks again.

请先登录,再进行评论。

回答(1 个)

Andrew Newell
Andrew Newell 2011-2-8

0 个投票

I'm not sure what your goal is, but the errors in the above code go away if you provide values for lat and long:
axesm('hammer');
lat = 0; long = 0;
patchm (lat, long, 'f');
setm (gca,'Origin', [30 130 135]);

5 个评论

Luke
Luke 2011-2-15
No sorry, I had arragned a similar code that gave the same disply but the problem axes to be because i have values to use
Luke
Luke 2011-2-15
for lat and long
Andrew Newell
Andrew Newell 2011-2-15
I don't understand what you are saying. Can you try editing the original question?
Luke
Luke 2011-2-15
Im trying to write an axesm function that will show the galactic plane. so far i bieleve that i have the basic script for it working but i am having problems setting the axes. i need then to be the right assention and declination for each corresponding data point we have observed. data that i already have?
I hope that clears it up for you
thanks
Luke
Luke 2011-2-15
Im trying to write an axesm function that will show the galactic plane. so far i bieleve that i have the basic script for it working but i am having problems setting the axes. i need then to be the right assention and declination for each corresponding data point we have observed. data that i already have?
I hope that clears it up for you
thanks

请先登录,再进行评论。

提问:

2011-2-8

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by