davidcarslaw / openair

Tools for air quality data analysis
https://davidcarslaw.github.io/openair/
GNU General Public License v2.0
304 stars 113 forks source link

trajCluster frequency (%) legend #33

Closed JulioCM closed 8 years ago

JulioCM commented 8 years ago

Not a bug. But it would be very nice if trajCluster could have the option of showing the frequencies of each cluster as the Hysplit GUI does.

davidcarslaw commented 8 years ago

Yes - good idea. I will do that shortly...

lyggd commented 8 years ago

Hi David, I just want to follow up that if you added this option to trajCluster. It will be very helpful. Thank you very much.

davidcarslaw commented 8 years ago

trajCluster should now add the percentage of total trajectories to each cluster. It will do this by default. Just let me know if there is a problem.

trajCluster(traj, method = "Angle", n.cluster = 8, map.cols = openColours("Paired", 10))

rplot

lyggd commented 8 years ago

David, I update my 'openair' package by require(devtools) install_github('davidcarslaw/openair') The code worked on last Friday, but it does not work today agaion. I can not see the percentage of total trajectories to each cluster. Would you check it for me ? Happy Chinese new year ! Yi

JulioCM commented 8 years ago

Great, many thanks David

lyggd commented 8 years ago

Sometimes if you do seasonal plots, the number of percentage will overlap, which is hard to read. If there any way to solve this problem ? Thanks cluster seaonal_map_o3

davidcarslaw commented 8 years ago

I did fix the decimal places - should only be one now. Also, try setting xlim and ylim to zoom in more to the map, which should improve clarity. It is quite hard to sort label placement automatically...

lyggd commented 8 years ago

Great ! Thanks a lot, David

JulioCM commented 8 years ago

only problem, how I can change the points size?

Many thanks

davidcarslaw commented 8 years ago

Do you mean the size of the font labels? You can change the overall size of fonts in openair function e.g.

trajCluster(traj, fontsize = 10)

Hopefully that will do what you want. I could add an option to specifically control the label size but I don't want too many options...

JulioCM commented 8 years ago

Many thanks David. I'am able to change the fontsize and the width of the lines (lwd) and it helps but I was hoping to also change the size of the dots (the ones that appear when you use npoints).