Universitas : Universitas Islam Negeri Maulana Malik Ibrahim Malang
Jurusan : Teknik Informatika
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 Sumatera 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>
plot(datainflow$Tahun,datainflow$`Sumatera`,type = "l", col= "steelblue")
plot(dataoutflow$Tahun,dataoutflow$`Sumatera`,type = "l", col= "red")
plot(datainflow$Tahun,datainflow$`Sumatera`,type = "l", col= "steelblue")
lines(dataoutflow$Tahun,dataoutflow$`Sumatera`,col="red")
legend("top",c("Inflow","Outflow"),fill=c("steelblue","red"))
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$`Sumatera`, type = "l", col = "green")
lines(dataoutflowperbulan$`Sumatera`,col="yellow")
legend("top",c("Inflow","Outflow"),fill=c("green","yellow"))
Sumateratimeseries <- datainflowperbulan$`Sumatera`
plot.ts(Sumateratimeseries , type = "l", col = "green")
logSumatera <- log(datainflowperbulan$`Sumatera`)
plot.ts(logSumatera)
Sumaterainflowtimeseries <- ts(datainflowperbulan$`Sumatera`, frequency=12, start=c(2011,1))
Sumaterainflowtimeseries
## Jan Feb Mar Apr May Jun Jul
## 2011 4164.243 3337.607 4878.287 3156.548 3821.275 3686.394 4369.643
## 2012 7371.435 5443.242 5022.248 4102.575 5321.981 4064.952 5489.699
## 2013 13436.780 8035.017 7017.142 8267.947 7623.367 6961.815 7552.290
## 2014 11612.677 6964.701 5238.644 5988.730 4921.418 5591.202 3440.204
## 2015 12838.000 5173.687 5600.472 4954.255 5358.552 5936.657 15050.224
## 2016 13692.690 7760.507 6313.597 5254.795 6761.434 5066.314 20548.504
## 2017 12734.711 7752.686 7568.883 6638.224 7317.874 4071.240 21208.720
## 2018 16240.858 7668.179 7130.231 7628.992 5973.344 19402.076 14326.890
## 2019 17413.907 9281.546 8215.984 9406.456 7523.072 26667.739 11014.410
## 2020 19330.620 10365.349 7128.873 6536.998 7788.132 14946.781 8278.451
## 2021 21182.291 9983.745 8648.731 9095.626 16275.454 10211.629 6787.420
## Aug Sep Oct Nov Dec
## 2011 3668.498 12874.594 4776.883 5669.993 3496.335
## 2012 9422.659 6813.338 4563.922 5452.494 2842.029
## 2013 19523.108 5265.619 6181.279 5347.888 3157.046
## 2014 19746.407 6305.927 6798.485 5515.775 3899.380
## 2015 8915.131 5710.106 6763.497 6087.162 4161.556
## 2016 6548.412 7498.570 6952.295 6098.330 5268.100
## 2017 8722.990 8250.898 7610.729 7122.755 4748.106
## 2018 9119.047 8886.660 8429.308 8078.990 4610.368
## 2019 10707.883 9462.332 10195.256 8492.726 5380.872
## 2020 8012.437 7559.106 5735.149 8462.623 5200.062
## 2021 7085.136
Sumateraoutflowtimeseries <- ts(dataoutflowperbulan$`Sumatera`, frequency=12, start=c(2011,1))
Sumateraoutflowtimeseries
## Jan Feb Mar Apr May Jun Jul
## 2011 3441.614 3989.113 4228.628 6721.276 5787.181 7394.536 7154.223
## 2012 3200.178 4100.054 6605.179 6665.551 7147.179 8560.319 7711.993
## 2013 2221.436 4621.158 8219.574 4613.748 8423.251 7790.216 17485.108
## 2014 4289.908 4820.657 7088.166 8015.452 7757.313 8157.185 24722.650
## 2015 2036.392 5682.352 6300.508 10051.597 7592.788 12421.852 22934.645
## 2016 2804.053 4909.740 6985.628 8649.278 10859.812 28813.953 6455.632
## 2017 4855.706 6495.905 9234.822 9234.883 11638.176 29889.710 3252.637
## 2018 2424.451 7487.879 10455.312 9952.146 19165.027 25439.136 6324.910
## 2019 3735.569 7719.811 11089.472 15127.060 37664.505 2465.417 10575.813
## 2020 4693.754 6958.705 12667.832 11775.906 19644.928 3971.849 12710.177
## 2021 1990.678 6099.024 9638.351 19930.265 22004.413 7748.386 11650.666
## Aug Sep Oct Nov Dec
## 2011 16042.967 1914.778 5173.616 5609.913 12634.335
## 2012 13610.489 3180.756 6273.015 5018.851 13161.070
## 2013 10207.967 6806.163 8014.259 8355.285 16529.555
## 2014 2377.454 6171.922 7655.389 7005.319 14276.798
## 2015 4668.410 6733.060 5783.016 8056.207 16924.980
## 2016 7937.744 10071.108 7571.519 9563.416 17369.845
## 2017 11015.435 6693.301 8559.331 12083.466 20652.339
## 2018 10042.081 7060.453 8155.825 9944.104 19225.025
## 2019 11780.050 8535.685 8868.257 12462.606 23460.023
## 2020 9744.450 9247.241 14431.727 9435.013 25307.224
## 2021 7565.509
plot.ts(Sumaterainflowtimeseries)
plot.ts(Sumateraoutflowtimeseries)
Sumateraintimeseriescomponents <- decompose(Sumaterainflowtimeseries)
Sumateraintimeseriescomponents$seasonal
## Jan Feb Mar Apr May Jun
## 2011 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2012 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2013 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2014 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2015 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2016 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2017 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2018 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2019 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2020 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## 2021 6152.5962 -614.2449 -1728.6408 -1759.2576 -1797.7115 1972.5387
## Jul Aug Sep Oct Nov Dec
## 2011 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2012 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2013 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2014 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2015 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2016 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2017 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2018 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2019 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2020 3070.5444 2282.6974 -336.6473 -1439.1383 -1683.5836 -4119.1528
## 2021 3070.5444 2282.6974
Sumateraouttimeseriescomponents <- decompose(Sumateraoutflowtimeseries)
Sumateraouttimeseriescomponents$seasonal
## Jan Feb Mar Apr May
## 2011 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2012 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2013 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2014 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2015 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2016 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2017 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2018 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2019 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2020 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## 2021 -6834.998330 -4154.095027 -1069.366771 -541.827422 4487.308681
## Jun Jul Aug Sep Oct
## 2011 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2012 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2013 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2014 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2015 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2016 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2017 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2018 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2019 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2020 4146.113221 2196.088359 3.268476 -3129.321269 -1799.750549
## 2021 4146.113221 2196.088359 3.268476
## Nov Dec
## 2011 -1217.537318 7914.117948
## 2012 -1217.537318 7914.117948
## 2013 -1217.537318 7914.117948
## 2014 -1217.537318 7914.117948
## 2015 -1217.537318 7914.117948
## 2016 -1217.537318 7914.117948
## 2017 -1217.537318 7914.117948
## 2018 -1217.537318 7914.117948
## 2019 -1217.537318 7914.117948
## 2020 -1217.537318 7914.117948
## 2021
plot(Sumateraintimeseriescomponents$seasonal,type = "l", col = "orange")
lines(Sumateraouttimeseriescomponents$seasonal,col="grey")
legend("top",c("Inflow","Outflow"),fill=c("orange","grey"))
plot(Sumateraintimeseriescomponents$trend,type = "l", col = "orange")
lines(Sumateraouttimeseriescomponents$trend,col="grey")
legend("top",c("Inflow","Outflow"),fill=c("orange","grey"))
plot(Sumateraintimeseriescomponents$random ,type = "l", col = "orange")
lines(Sumateraouttimeseriescomponents$random,col="grey")
legend("top",c("Inflow","Outflow"),fill=c("orange","grey"))
plot(Sumateraintimeseriescomponents$figure ,type = "l", col = "orange")
lines(Sumateraouttimeseriescomponents$figure,col="grey")
legend("top",c("Inflow","Outflow"),fill=c("orange","grey"))