Universitas : Universitas Islam Negeri Maulana Malik Ibrahim Malang

Jurusan : Teknik Informatika

Inflow - Outflow

Inflow disebut investasi sebagai langsung dalam ekonomi pelaporan, termasuk semua kewajiban dan aset yang ditransfer antara perusahaan investasi langsung penduduk dan investor langsung mereka. Ini juga mencakup transfer aset dan kewajiban antara perusahaan yang bertempat tinggal dan yang tidak residen, jika orang tua pengendali utama adalah bukan penduduk.

Outflow disebut sebagai investasi langsung di luar negeri, termasuk aset dan kewajiban yang ditransfer antara investor langsung penduduk dan perusahaan investasi langsung mereka.

contoh penerapan visualisasi prediksi data Inflow-Outflow Uang Kartal di Jambi menggunakan bahasa pemrograman R.

library(readxl)
## Warning: package 'readxl' was built under R version 4.1.2
datainflow <- read_excel(path = "inflowTahunan.xlsx")
datainflow
## # A tibble: 11 x 12
##    Tahun Sumatera   Aceh `Sumatera Utara` `Sumatera Barat`   Riau `Kep. Riau`
##    <dbl>    <dbl>  <dbl>            <dbl>            <dbl>  <dbl>       <dbl>
##  1  2011   57900.  2308.           23238.            9385.  3012.       1426.
##  2  2012   65911.  2620.           25981.           11192.  4447.       2236.
##  3  2013   98369. 36337.           18120.           14056.  8933.       3378.
##  4  2014   86024.  4567.           30503.           14103.  6358.       2563.
##  5  2015   86549.  4710.           30254.           13309.  7156.       3218.
##  6  2016   97764.  5775.           34427.           14078.  8211.       4317.
##  7  2017  103748.  5514.           35617.           15312.  8553.       4412.
##  8  2018  117495.  5799.           41769.           15058. 10730.       5134.
##  9  2019  133762.  7509.           47112.           14750. 10915.       6077.
## 10  2020  109345.  6641.           36609.           10696.  9148.       6175.
## 11  2021   89270.  3702.           31840.           10748.  7769.       5009.
## # ... with 5 more variables: Jambi <dbl>, Sumatera Selatan <dbl>,
## #   Bengkulu <dbl>, Lampung <dbl>, Kep. Bangka Bellitung <dbl>
library (readxl)
dataoutflow <- read_excel(path = "outflowTahunan.xlsx")
dataoutflow
## # A tibble: 11 x 12
##    Tahun Sumatera   Aceh `Sumatera Utara` `Sumatera Barat`   Riau `Kep. Riau`
##    <dbl>    <dbl>  <dbl>            <dbl>            <dbl>  <dbl>       <dbl>
##  1  2011   80092.  6338.           22176.            5300. 12434.       5819.
##  2  2012   85235.  6378.           22495.            6434. 13014.       6966.
##  3  2013  103288. 23278.           19235.            6511. 15460.       8747.
##  4  2014  102338.  8630.           26391.            7060. 15158.      10122.
##  5  2015  109186.  9637.           27877.            7471. 15789.       9803.
##  6  2016  121992. 11311.           31959.            9198. 17645.      10068.
##  7  2017  133606. 11760.           35243.           10754. 18128.      10749.
##  8  2018  135676. 11450.           36908.            8447. 17926.      12597.
##  9  2019  153484. 13087.           44051.            9465. 19277.      12644.
## 10  2020  140589. 12874.           39758.            8763. 19139.       8461.
## 11  2021   86627.  5770.           23453.            5941. 12631.       5128.
## # ... with 5 more variables: Jambi <dbl>, Sumatera Selatan <dbl>,
## #   Bengkulu <dbl>, Lampung <dbl>, Kep. Bangka Bellitung <dbl>

1.Visualisasi Prediksi Data Inflow Uang Kartal Jambi setiap periode

plot(datainflow$Tahun,datainflow$`Jambi`,type = "l", col= "steelblue")

2.Visualisasi Prediksi Data outflow Uang Kartal Jambi setiap periode

plot(dataoutflow$Tahun,dataoutflow$`Jambi`,type = "l", col= "red")

3.Visualisasi Prediksi Data Inflow-Outflow Uang Kartal di Jambi Setiap Periode

plot(datainflow$Tahun,datainflow$`Jambi`,type = "l", col= "steelblue")
lines(dataoutflow$Tahun,dataoutflow$`Jambi`,col="red")
legend("top",c("Inflow","Outflow"),fill=c("steelblue","red"))

4. Visualisasi Prediksi Data Inflow-Outflow Uang Kartal di Jambi Setiap Bulan

library(readxl)
datainflowperbulan <- read_excel(path = "inflowbulanan.xlsx")
dataoutflowperbulan <- read_excel(path = "outflowbulanan.xlsx")
datainflowperbulan
## # A tibble: 128 x 12
##    keterangan          Sumatera  Aceh `Sumatera Utara` `Sumatera Barat`   Riau
##    <dttm>                 <dbl> <dbl>            <dbl>            <dbl>  <dbl>
##  1 2011-01-01 00:00:00    4164.  124.            2068.             545.   94.2
##  2 2011-02-01 00:00:00    3338.  115.            1826.             450.   96.4
##  3 2011-03-01 00:00:00    4878.  154.            2028.             849.  288. 
##  4 2011-04-01 00:00:00    3157.  122.            1429.             539.  160. 
##  5 2011-05-01 00:00:00    3821.  123.            1539.             692.  195. 
##  6 2011-06-01 00:00:00    3686.  151.            1637.             592.  101. 
##  7 2011-07-01 00:00:00    4370.  107.            1791.             800.  143. 
##  8 2011-08-01 00:00:00    3668.  184.            1256.             586.  134. 
##  9 2011-09-01 00:00:00   12875.  606.            4172.            2176. 1014. 
## 10 2011-10-01 00:00:00    4777.  158.            1941.             787.  341. 
## # ... with 118 more rows, and 6 more variables: Kep. Riau <dbl>, Jambi <dbl>,
## #   Sumatera Selatan <dbl>, Bengkulu <dbl>, Lampung <dbl>,
## #   Kep. Bangka Belitung <dbl>
dataoutflowperbulan
## # A tibble: 128 x 12
##    keterangan          Sumatera  Aceh `Sumatera Utara` `Sumatera Barat`  Riau
##    <dttm>                 <dbl> <dbl>            <dbl>            <dbl> <dbl>
##  1 2011-01-01 00:00:00    3442.  350.             941.             307.  478.
##  2 2011-02-01 00:00:00    3989.  193.             990.             228.  400.
##  3 2011-03-01 00:00:00    4229.  230.            1209.             347.  621.
##  4 2011-04-01 00:00:00    6721.  529.            1653.             336. 1006.
##  5 2011-05-01 00:00:00    5787.  523.            1465.             328. 1000.
##  6 2011-06-01 00:00:00    7395.  406.            2167.             399. 1366.
##  7 2011-07-01 00:00:00    7154.  958.            1695.             449.  815.
##  8 2011-08-01 00:00:00   16043. 1046.            4104.            1376. 2729.
##  9 2011-09-01 00:00:00    1915.  124.             824.             148.  154.
## 10 2011-10-01 00:00:00    5174.  634.            1392.             299.  830.
## # ... with 118 more rows, and 6 more variables: Kep. Riau <dbl>, Jambi <dbl>,
## #   Sumatera Selatan <dbl>, Bengkulu <dbl>, Lampung <dbl>,
## #   Kep. Bangka Belitung <dbl>
plot(datainflowperbulan$`Jambi`, type = "l", col = "green")
lines(dataoutflowperbulan$`Jambi`,col="yellow")
legend("top",c("Inflow","Outflow"),fill=c("green","yellow"))

Jambitimeseries <- datainflowperbulan$`Jambi`
plot.ts(Jambitimeseries , type = "l", col = "green")

logJambi <- log(datainflowperbulan$`Jambi`)
plot.ts(logJambi)

5. Visualisasi Prediksi Data Inflow-Outflow Time Series Uang Kartal di Jambi

Jambiinflowtimeseries <- ts(datainflowperbulan$`Jambi`, frequency=12, start=c(2011,1))
Jambiinflowtimeseries
##             Jan        Feb        Mar        Apr        May        Jun
## 2011   48.21238   39.91336  202.77581   76.36759  102.29337   80.38363
## 2012  214.78357  185.06614  118.25569  112.18712  176.73267  131.65442
## 2013  440.25724  250.16557  156.40296  131.70444   80.43460   90.88444
## 2014  648.84622  443.17728  218.60749  372.98546  277.49781  326.07002
## 2015  800.91577  310.67803  334.27000  339.99797  285.21811  266.80514
## 2016  723.86727  399.44327  227.89071  207.32596  294.89205  265.25147
## 2017  436.71704  349.18620  374.44420  291.87853  265.93193  109.35945
## 2018  850.92308  423.79251  432.57396  284.21732  331.44473  943.33760
## 2019  928.32921  508.44605  501.71263  395.87576  375.81227 1377.08370
## 2020  929.25223  453.21208  375.57835  488.00832  366.02264  926.36280
## 2021 1319.31010  533.89020  481.47669  442.30053  954.47189  568.16022
##             Jul        Aug        Sep        Oct        Nov        Dec
## 2011  118.45074   91.88117  618.33464  137.23519  238.83742  112.93547
## 2012  178.67562  446.70847  180.60249   96.89252  190.29249  106.61224
## 2013  150.73569  696.17818  239.01380  381.11280  240.84581  189.04884
## 2014  228.38825 1336.65537  383.31015  366.82210  328.60113  238.13597
## 2015 1033.05014  473.13670  295.54859  329.75416  266.79923  241.96031
## 2016 1069.41796  211.81993  325.26906  251.99989  234.81316  186.17002
## 2017 1008.96424  331.35488  369.25742  288.45059  300.80490  277.28824
## 2018  555.66909  452.09732  390.12811  409.82051  356.98477  225.60052
## 2019  517.64046  582.60662  370.00861  477.26284  302.21112  149.17703
## 2020  418.88012  362.62433  363.94528  290.43227  404.08403  249.99980
## 2021  337.72947  342.40788
Jambioutflowtimeseries <- ts(dataoutflowperbulan$`Jambi`, frequency=12, start=c(2011,1))
Jambioutflowtimeseries
##             Jan        Feb        Mar        Apr        May        Jun
## 2011  297.46348  280.08970  341.37188  474.26014  371.36905  540.43609
## 2012  133.61579  321.29557  315.41057  373.26078  441.58952  474.63459
## 2013  110.31731  184.50535  223.54744  235.42017  450.54670  349.51626
## 2014  351.35683  459.63127  637.62828  526.41165  683.34064  651.89272
## 2015  249.99472  486.10988  549.06994  721.86428  701.16932  931.14718
## 2016  229.69662  442.46621  487.32817  572.51965  587.13872 1610.89703
## 2017  394.17886  553.63581  500.03923  530.31764  570.86673 1961.91565
## 2018  275.03184  451.87980  498.71186  687.34280 1222.83919 1579.32715
## 2019  218.20233  534.52562  559.51510  895.65817 2018.12386  147.10847
## 2020  230.43948  421.99569  606.04929  713.68012 1262.75583  143.79548
## 2021   54.41456  487.87292  732.48101 1261.14201 1578.66374  642.31328
##             Jul        Aug        Sep        Oct        Nov        Dec
## 2011  428.10203 1056.05643   92.78528  295.39728  272.21261  767.15036
## 2012  330.20592  835.74847  221.85612  472.49384  299.07579  794.04754
## 2013  839.48154  339.88048  732.69193  819.24007  782.02490 1235.18658
## 2014 1929.38736  274.46904  553.86575  703.65271  588.68032 1000.86095
## 2015 1582.71912  395.76377  549.45261  479.75684  631.21748 1046.24662
## 2016  456.38157  430.25770  842.64910  521.69293  648.58138  944.35648
## 2017  212.49734  680.41258  470.55865  568.53590  820.95090 1169.98413
## 2018  391.43773  555.29629  475.32140  545.11918  735.03562 1042.05433
## 2019  717.81375  656.73797  617.28665  719.15618  727.75492 1392.15834
## 2020  633.64958  610.36918  689.06184 1124.09728  807.10093 1706.97368
## 2021  664.55917  624.91746
plot.ts(Jambiinflowtimeseries)

plot.ts(Jambioutflowtimeseries)

Jambiintimeseriescomponents <- decompose(Jambiinflowtimeseries)
Jambiintimeseriescomponents$seasonal
##             Jan        Feb        Mar        Apr        May        Jun
## 2011  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2012  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2013  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2014  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2015  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2016  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2017  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2018  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2019  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2020  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
## 2021  331.44588  -14.12609  -81.49621  -93.86719 -114.25191  104.66208
##             Jul        Aug        Sep        Oct        Nov        Dec
## 2011  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2012  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2013  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2014  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2015  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2016  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2017  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2018  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2019  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2020  156.97755  120.14214  -28.04183  -81.29134 -102.91768 -197.23539
## 2021  156.97755  120.14214
Jambiouttimeseriescomponents <- decompose(Jambioutflowtimeseries)
Jambiouttimeseriescomponents$seasonal
##             Jan        Feb        Mar        Apr        May        Jun
## 2011 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2012 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2013 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2014 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2015 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2016 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2017 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2018 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2019 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2020 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
## 2021 -429.76166 -219.28351 -144.71768  -53.62864  238.04681  221.42655
##             Jul        Aug        Sep        Oct        Nov        Dec
## 2011  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2012  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2013  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2014  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2015  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2016  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2017  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2018  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2019  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2020  120.11152  -48.40994 -109.85159  -14.39860  -16.35840  456.82513
## 2021  120.11152  -48.40994
plot(Jambiintimeseriescomponents$seasonal,type = "l", col = "orange")
lines(Jambiouttimeseriescomponents$seasonal,col="grey")
legend("top",c("Inflow","Outflow"),fill=c("orange","grey"))

plot(Jambiintimeseriescomponents$trend,type = "l", col = "orange")
lines(Jambiouttimeseriescomponents$trend,col="grey")
legend("top",c("Inflow","Outflow"),fill=c("orange","grey"))

plot(Jambiintimeseriescomponents$random ,type = "l", col = "orange")
lines(Jambiouttimeseriescomponents$random,col="grey")
legend("top",c("Inflow","Outflow"),fill=c("orange","grey"))

plot(Jambiintimeseriescomponents$figure ,type = "l", col = "orange")
lines(Jambiouttimeseriescomponents$figure,col="grey")
legend("top",c("Inflow","Outflow"),fill=c("orange","grey"))