<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Zakiya Azizah Cahyaningtyas on Medium]]></title>
        <description><![CDATA[Stories by Zakiya Azizah Cahyaningtyas on Medium]]></description>
        <link>https://medium.com/@zumazaki?source=rss-bdcbd2b10d25------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*0KpUr5ToJX5qzBMS</url>
            <title>Stories by Zakiya Azizah Cahyaningtyas on Medium</title>
            <link>https://medium.com/@zumazaki?source=rss-bdcbd2b10d25------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 23 Nov 2026 07:26:04 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@zumazaki/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Using Joyplot on Gold Price Data]]></title>
            <link>https://medium.com/@zumazaki/using-joyplot-on-gold-price-data-802187536e85?source=rss-bdcbd2b10d25------2</link>
            <guid isPermaLink="false">https://medium.com/p/802187536e85</guid>
            <category><![CDATA[data-visualization]]></category>
            <category><![CDATA[data]]></category>
            <dc:creator><![CDATA[Zakiya Azizah Cahyaningtyas]]></dc:creator>
            <pubDate>Thu, 11 Aug 2022 13:52:59 GMT</pubDate>
            <atom:updated>2022-08-11T14:01:26.811Z</atom:updated>
            <content:encoded><![CDATA[<p>Today was my day off, and I’m already off any academic affairs since I’m graduating soon (yay! 😃). Anyway, I was bored and curious about this Joyplot introduced by an acquaintance. Long story short, I found a use case to use Joyplot on gold price data. But since I have a whole day to play around, I tried to forecast this year’s (2022) gold price median and compare it to the current median.</p><p>For this lite experiment, I put the code and data in my GitHub repo:</p><p><a href="https://github.com/coll-j/playground/tree/main/gold_joyplot">playground/gold_joyplot at main · coll-j/playground</a></p><p>or you can find the notebook only here:</p><p><a href="https://colab.research.google.com/drive/1byvlozKd5MOx1pjE28kD3B3lRacePYyG?usp=sharing">Google Colaboratory</a></p><h3><strong>Data</strong></h3><p>I used the data from this website: <a href="https://id.investing.com/commodities/gold-historical-data">https://id.investing.com/commodities/gold-historical-data</a>, which records the gold price in USD per Troy Ounce. I take the data from the earliest year possible (1975). You can find the data in the repo for this project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/604/1*Roh88KbLchbfm7AhmKnJ1A.png" /><figcaption>The X-axis (Tahun) denotes the Year; Y-axis denotes gold price in USD per Troy Ounce</figcaption></figure><h3><strong>Forecasting</strong></h3><p>This was a quick trial, so I only used one predictive forecasting model: Gradient Boosting Regressor. If you want to read more about this algorithm, I found this <a href="https://towardsdatascience.com/all-you-need-to-know-about-gradient-boosting-algorithm-part-1-regression-2520a34a502">Medium article</a> to be illustrative.</p><p>I’m aware that gold price is affected by other factors, such as other commodities, world (economics, especially) events, etc. So, a bit disclaimer as well, I know you can’t just take the prediction as is. This was purely to fulfill my curiosity. I applied a prediction interval on top of the regressor to make it more general. Which is defined as:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/487/1*3KiKEocTQ5aMXX3MpxGqnQ.png" /><figcaption>Prediction Interval Formula © <a href="https://zluvsand.medium.com/?source=post_page-----64b992317b1a--------------------------------">Luvsandorj</a> on <a href="https://towardsdatascience.com/prediction-intervals-in-python-64b992317b1a">Medium</a></figcaption></figure><p>Where</p><ul><li>y_hat is the prediction, and y is the actual value (median of gold price),</li><li>t is the t-statistic value from alpha (0.05 was used for the alpha),</li><li>n is the number of observation</li></ul><p>you can read more about this in Luvsandorj’s article here: <a href="https://towardsdatascience.com/prediction-intervals-in-python-64b992317b1a">https://towardsdatascience.com/prediction-intervals-in-python-64b992317b1a</a></p><p>The result yields the following number as the forecast:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/492/1*6zMNYutNnWZftpmn_48_lw.png" /></figure><h3><strong>Visualization, Joyplot!</strong></h3><p>Now that we have the result yielded for the current year, we want to plot and compare it using Joyplot. In this work, I used the <a href="https://github.com/leotac/joypy">Joyplot Python library</a> built over Matplotlib. Here, I only plot the gold price for the past 12 years, 2011–2022:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/568/1*ZpgpW0wD0SoIOPXLUJbEhA.png" /><figcaption>JoyPlot of Yearly Median Gold Price</figcaption></figure><p>Here, the prediction is denoted by the dashed green line, while the rectangle area denotes the prediction interval. Nothing much to take from this, but the prediction seems to be lower than the current median. If the prediction is correct, we can expect a drop in gold prices for the rest of the year. But then again, I need to emphasize that <strong>you can’t take this result as is</strong> since gold price calculation is waaay more complex than what I did here. However, It was fun trying out Joyplot and applying prediction intervals for me. Cheers, and thank you for reading! 😃</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=802187536e85" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>