For this assignment, I asked ChatGPT to create a time series visualization in R using ggplot2. I wanted to use the ‘Temp’ variable from RStudio’s built in dataset ‘airquality’.
After some adjusting, here is the final result:
I gave the input “Write r code using ggplot2 to create a time series visualization of temp from airquality dataset” to ChatGPT. I provided the instructions for the type of visualization I wanted, and ChatGPT generated the code for me, which I entered into RStudio and created the plot. I did not encounter many challenges. The only changes I made to the original code were adjusting the colors and title to better match my preferences. Telling the AI exactly what I want seems to work best. The more detailed, the better. Otherwise, it makes choices that I might not want leading to going through the code to change/edit.
In this instance, ChatGPT did not really feel like a collaborator because it completed most of the work for me, and I only made minor edits. I think it would feel more collaborative if I wrote the code myself and used ChatGPT for troubleshooting, making improvements, or suggesting different approaches. Having it provide feedback and offer a different perspective would make it feel more like working with a partner rather than simply having it do the work for me.
Leave a Reply