You're welcome! Happy that my new tutorial is useful
@oumardiallo7292
Жыл бұрын
Thanks for the tut. That was very neat. I love your map viz
@milos-makes-maps
Жыл бұрын
You're welcome! Thanks for the kind words and the encouragement to keep it going 😊🙏🏼
@pavloshevchuk2454
Жыл бұрын
You did a great job, Milos! I wish that you would have more subscribers.
@milos-makes-maps
Жыл бұрын
Thank you dear Pavlo for your kind comment! It takes time to build up the channel but I really enjoy interactions with you guys while the channel is small and cozy 😀
@AleksPopovic
Жыл бұрын
Cool animations tutorial Milos!
@milos-makes-maps
Жыл бұрын
Happy you like it 😁. It took some time to make it but it was totally worth it
@kunalkunal6227
Жыл бұрын
Would it be possible for you to create a tutorial on how to work with netCDF files, using any variable such as surface temperature from satellite data in a netCDF (.nc) file? I have noticed that many people in the atmospheric science community who work with satellite and model data tend to use Python for data analysis, and there is a wide range of Python-based tutorials available. However, it seems that tutorials on handling netCDF files using R are still lacking or not as advanced as those for Python. As a result, many in the atmospheric science community prefer using Python for plotting spatial maps. So I guess, if you can make a series on this topic that would be great.
@milos-makes-maps
Жыл бұрын
That's an excellent proposition! I've worked with .nc files in R before so making a tutorial on handling/making those files is on my agenda!
@Aaqib..
Жыл бұрын
Thats so true.
@Aaqib..
Жыл бұрын
@@milos-makes-maps thank you
@kevinmorgan4234
Жыл бұрын
Thank You Milos that was a great tutorial. Question that I came away with after watching is whether this can be integrated into a R-Markdown file or do you have to save the GIF animation as a standalone?
@milos-makes-maps
Жыл бұрын
Hi Kevin, I bumped into two solutions on Stackoverflow that discuss exporting gganimate objects to html and pdf. stackoverflow.com/questions/53876485/how-to-render-a-gganimate-graph-in-html-using-rmarkdownrender-without-gener stackoverflow.com/questions/63042208/rmarkdown-rendering-to-a-pdf-that-uses-gganimate
@kevinmorgan4234
Жыл бұрын
@@milos-makes-maps I will check it out. Thank You Milos.
@pavloshevchuk2454
Жыл бұрын
Dear Milos, I have reproduced your map using my data. It works well. However, I don't understand the legend's breaks in the legend. Your data are continuous. Look at the labels. Under the first key rectangle is 0. So, I assume this colour represents values between 0 and the next one, which is 11.5. The next colour (correct me if I'm wrong) represents values between 11.5 and 27.8 and so on. Using this logic, the penultimate colour represents values between 80.1 and 100. What represents the last coloured rectangle?
@milos-makes-maps
Жыл бұрын
Hi Pavlo, you're right the scale is continuous and the breaks are confusing because the legend keys and breaks don't always correspond to each other. That's why I usually go for discrete legend keys because then legend keys and labels correspond to each other. But in this case I as a bit lazy and went for an easier solution. Funny, many people ask me to use bins like this one instead of discrete keys. In this case, you can think of breaks as markers that are close enough to the nearby color. So, they don't represent from-to-value. The last colored rectangle always shows the maximum value (100 in this case) while the first shows the minimum (0 in this case)
@pavloshevchuk2454
Жыл бұрын
@@milos-makes-maps Thank you, Milos! My data on the map can be confusing in itself. Besides, this kind of visualisation is usually made for demonstrations to other people. There is no need to make it more difficult to understand. I'll try (I'm not very experienced) to rewrite your code for the case of discrete breaks. Thanks for the explanation!
@julianandressalazar5755
Жыл бұрын
Hi Milos! I was trying to follow your tutorial, but when I run the next code I have this error: > animated_world
@milos-makes-maps
Жыл бұрын
Hi Julián! It's my pleasure to share knowledge with R community! Thanks for flagging the error. Some folks have already warned me about experiencing `Error: arguments have different crs` when they run the code. The issue is with gganimate 1.0.8. I have gganimate 1.0.7, which explains why I didn't get this error. Several possibilities to resolve this error are explained in the accepted answer of this post: stackoverflow.com/questions/75900914/problem-animating-with-geom-sf-and-gganimate-error-arguments-have-different-cr. However, if none of them work, please uninstall your current version and install gganimate 1.0.7.
@zabihullahazimy5046
Жыл бұрын
This part gives the following error: animated_world
@milos-makes-maps
Жыл бұрын
Hi! The error message "arguments have different crs" indicates that there are spatial objects or data frames with different coordinate reference systems (CRS) being used in your code. This can occur when you are trying to combine or plot spatial data that have different CRS settings. To address this issue, you can try the following steps: 1) Check the CRS of each spatial object or data frame: Use the st_crs() function from the sf package to inspect and compare the CRS of each spatial object. 2) Ensure CRS consistency: If you find that the CRS settings are different, you can use the st_transform() function from the sf package to transform the spatial objects to a consistent CRS. 3) Recheck the data and attempt the operation again: After ensuring that all spatial objects have the same CRS, try running your code or operation again to see if the error is resolved. Btw, the warning messages you encountered regarding NAs introduced by coercion may be related to data type mismatches or issues in your data. You may need to examine and clean your data to ensure consistency and correctness. If the issue persists or if you need further assistance, please provide additional details about the specific data and operations you are working with so that I can help you more effectively.
@zabihullahazimy5046
Жыл бұрын
@@milos-makes-maps thank you so much for your reply. I first tried to run the exact same code, but it showed me the error. After solving this, I will modify this for COVID dataset Thanks again
@milos-makes-maps
Жыл бұрын
@@zabihullahazimy5046 I'm glad if it works now! Let me know how it goes
@zabihullahazimy5046
Жыл бұрын
I have tried the very same code, but it shows the same error. I'm running it on Mac M1 chip. Does it also have to do anything with that?
@milos-makes-maps
Жыл бұрын
@@zabihullahazimy5046Let's debug it! Could you open a GitHub repo, store your code there and send me an invitation to it?
Пікірлер: 27