0.0.1 Dosen Pengampu : Prof. Dr. Suhartono, M.Kom

0.0.2 Lembaga : Universitas Islam Negeri Maulana Malik Ibrahim Malang

0.0.3 Jurusan : Teknik Informatika

0.0.4 Fakultas : Sains dan Teknologi

0.1 Data Inflow-OutFlow Pertahun untuk Wilayah Kalimantan dan Sekitarnya

library(readxl)
## Warning: package 'readxl' was built under R version 4.1.2
datainflow <- read_excel(path = "C:/Users/shafira halmahera/Documents/LINEAR ALGEBRA/Data Perbulan Inflow Kalimantan.xlsx")
datainflowtahun <- datainflow[c(1:12),c(1:6)]
datainflowtahun
library(readxl)
dataoutflow <- read_excel(path = "C:/Users/shafira halmahera/Documents/LINEAR ALGEBRA/Data Perbulan Outflow Kalimantan.xlsx")
dataoutflow

0.2 1. Komparasi Visualisasi Prediksi Data Inflow Uang Kartal di Wilayah Kalimantan dan Kalimantan Selatan Setiap Periode

plot(datainflow$Tahun,datainflow$`SKalimantan`,type = "l", col= "dodgerblue")
lines(datainflow$Tahun,datainflow$Riau,col="red")
legend("top",c("Inflow Kllimantan","Kalimantan Selatan"),fill=c("dodgerblue","red"))

0.3 2. Komparasi Visualisasi Prediksi Data Outflow Uang Kartal di Wilayah Kalimantan dan Kalimantan Timur Setiap Periode

plot(dataoutflow$Tahun,dataoutflow$`Sumatera Selatan`,type = "l", col= "yellow")
lines(dataoutflow$Tahun,dataoutflow$Riau,col="mediumorchid")
legend("top",c("Outflow Kalimantan Selatan","Kalimantan Timur"),fill=c("yellow","mediumorchid"))

0.4 3. Komparasi Visualisasi Prediksi Data Inflow-Outflow Uang Kartal di Wilayah Kalimantan dan Kalimantan Utara Setiap Periode

plot(datainflow$Tahun,datainflow$`Sumatera Selatan`,type = "l", col= "dodgerblue")
lines(datainflow$Tahun,datainflow$Riau,col="red")
lines(dataoutflow$Tahun,dataoutflow$`Sumatera Selatan`, col= "green")
lines(dataoutflow$Tahun,dataoutflow$Riau,col="mediumorchid")
legend("top",c("Inflow Kalimantan Selatan","Inflow Kalimantan Tengah","Outflow Kalimantan Utara","Outflow Kalimantan Timur "),fill=c("dodgerblue","red","green","mediumorchid"))

0.5 4. Komparasi Visualisasi Prediksi Data Inflow-Outflow Uang Kartal di Wilayah Kalimantan Setiap Bulan

library(readxl)
datainflowperbulan <- read_excel(path = "C:/Users/shafira halmahera/Documents/LINEAR ALGEBRA/Data Perbulan Inflow Kalimantan.xlsx")
dataoutflowperbulan <- read_excel(path = "C:/Users/shafira halmahera/Documents/LINEAR ALGEBRA/Data Perbulan Outflow Kalimantan.xlsx")
datainflowperbulan
dataoutflowperbulan
KalimantanSelatantimeseries <- datainflowperbulan$`Kalimantan Selatan`
Kalimantantimeseries <- datainflowperbulan$Kalimantan
plot.ts(KalimantanSelatantimeseries , type = "l", col = "cyan")
lines(Kalimantantimeseries , type = "l", col = "darkorchid")
legend("top",c("Kalimantan Selatan Timeseries","Kalimantan Timur Timeseries"),fill=c("cyan","darkorchid"))

plot(datainflowperbulan$`Kalimantan Selatan`, type = "l", col = "tomato")
lines(datainflowperbulan$Kalimantan,col="darkorchid")
lines(dataoutflowperbulan$`Kalimantan Selatan`, col = "green")
lines(dataoutflowperbulan$Kalimantan,col="purple")
legend("top",c("Inflow Kalimantan Selatan","Inflow Kalimantan","Outflow Kalimantan Selatan","Outflow Kalimantan"),fill=c("tomato","darkorchid","green","purple"))

KalimantanSelatantimeseries <- datainflowperbulan$`Kalimantan Selatan`
Kalimantantimeseries <- datainflowperbulan$Kalimantan
plot.ts(KalimantanSelatantimeseries , type = "l", col = "cyan")
lines(Kalimantantimeseries , type = "l", col = "darkorchid")
legend("top",c("Kalimantan Selatan Timeseries","Kalimantan Timeseries"),fill=c("cyan","darkorchid"))

library(TTR)
## Warning: package 'TTR' was built under R version 4.1.2

0.6 5. Komparasi Visualisasi Prediksi Data Inflow-Outflow Time Series Uang Kartal di Wilayah Kalimantan

KalimantanSelataninflowtimeseries <- ts(datainflowperbulan$`Kalimantan Selatan`, frequency=12, start=c(2011,1))
Kalimantaninflowtimeseries <- ts(datainflowperbulan$`Kalimantan Selatan`, frequency=12, start=c(2011,1))
KalimantanSelataninflowtimeseries
##             Jan        Feb        Mar        Apr        May        Jun
## 2011  104.71966   55.78300   64.28767   45.19356   45.99100   74.64779
## 2012  200.06448  102.71009   62.69569   85.78396   71.78199   74.40131
## 2013 3260.09114 1844.80157 1692.10915 1863.09219 1682.08817 1470.77087
## 2014  343.58319  113.46686   91.14619   67.97726  101.82439  109.95170
## 2015  505.84765  247.81308  227.75714  166.65411  224.50076  290.86845
## 2016  615.48752  248.94332  301.05825  179.74887  227.53505  163.75339
## 2017  615.64887  290.03319  287.84964  285.12107  269.17047   59.70408
## 2018  614.70999  265.27654  218.92177  218.32437  175.13672  706.46821
## 2019  704.79912  293.79454  334.74767  338.00939  101.96037  694.81639
## 2020  599.16605  334.57580  265.92791  295.41042  242.40389  555.35972
## 2021  897.47547  385.60604  342.62656  195.70149  703.86907  369.18861
##             Jul        Aug        Sep        Oct        Nov        Dec
## 2011   34.20407   24.01165  212.53945   29.67208   73.33386   14.43373
## 2012   89.07459  123.79065   72.76016  120.00007  102.77912   28.99388
## 2013 1516.74876 5562.79685  136.50999  143.26117  103.04464   52.61722
## 2014   43.70730  432.68781  176.28005  178.22549  149.29007   79.26257
## 2015  661.93813  281.15367  324.12220  245.39273  243.58708  127.26031
## 2016  718.34960  256.10090  250.35439  260.45869  239.35862  233.14767
## 2017  559.23596  335.15250  291.21939  318.95467  243.93971   99.16539
## 2018  377.91376  292.09641  408.36407  341.38267  291.04323  173.49785
## 2019  344.57313  343.42400  395.30119  356.28819  298.37122  179.15194
## 2020  380.22179  428.16861  280.71102  308.13016  322.66512  165.52683
## 2021  285.83449  353.90169
Kalimantaninflowtimeseries
##             Jan        Feb        Mar        Apr        May        Jun
## 2011  104.71966   55.78300   64.28767   45.19356   45.99100   74.64779
## 2012  200.06448  102.71009   62.69569   85.78396   71.78199   74.40131
## 2013 3260.09114 1844.80157 1692.10915 1863.09219 1682.08817 1470.77087
## 2014  343.58319  113.46686   91.14619   67.97726  101.82439  109.95170
## 2015  505.84765  247.81308  227.75714  166.65411  224.50076  290.86845
## 2016  615.48752  248.94332  301.05825  179.74887  227.53505  163.75339
## 2017  615.64887  290.03319  287.84964  285.12107  269.17047   59.70408
## 2018  614.70999  265.27654  218.92177  218.32437  175.13672  706.46821
## 2019  704.79912  293.79454  334.74767  338.00939  101.96037  694.81639
## 2020  599.16605  334.57580  265.92791  295.41042  242.40389  555.35972
## 2021  897.47547  385.60604  342.62656  195.70149  703.86907  369.18861
##             Jul        Aug        Sep        Oct        Nov        Dec
## 2011   34.20407   24.01165  212.53945   29.67208   73.33386   14.43373
## 2012   89.07459  123.79065   72.76016  120.00007  102.77912   28.99388
## 2013 1516.74876 5562.79685  136.50999  143.26117  103.04464   52.61722
## 2014   43.70730  432.68781  176.28005  178.22549  149.29007   79.26257
## 2015  661.93813  281.15367  324.12220  245.39273  243.58708  127.26031
## 2016  718.34960  256.10090  250.35439  260.45869  239.35862  233.14767
## 2017  559.23596  335.15250  291.21939  318.95467  243.93971   99.16539
## 2018  377.91376  292.09641  408.36407  341.38267  291.04323  173.49785
## 2019  344.57313  343.42400  395.30119  356.28819  298.37122  179.15194
## 2020  380.22179  428.16861  280.71102  308.13016  322.66512  165.52683
## 2021  285.83449  353.90169
KalimantanSelatanoutflowtimeseries <- ts(dataoutflowperbulan$`Kalimantan Selatan`, frequency=12, start=c(2011,1))
Kalimantanoutflowtimeseries <- ts(dataoutflowperbulan$Kalimantan, frequency=12, start=c(2011,1))
KalimantanSelatanoutflowtimeseries
##             Jan        Feb        Mar        Apr        May        Jun
## 2011   30.92676  217.58423  331.32386  349.56174  338.01996  442.51594
## 2012   78.01497  251.83107  418.87169  320.11813  425.22442  617.59797
## 2013   53.28767  173.17133  229.16928  159.83154  564.48615  283.19700
## 2014  205.72818  297.56403  516.77520  462.29009  382.51735  459.45448
## 2015  145.86699  280.42443  375.57112  524.22672  390.50958  765.86225
## 2016  119.98024  321.23994  292.72978  483.17704  707.14356 1745.73473
## 2017  220.74825  470.94490  677.64512  803.43306  894.74852 2335.48989
## 2018  119.70985  411.30635  858.73024  569.53375 1311.73154 1745.23677
## 2019  156.83052  402.14036  735.27418 1026.22248 2307.99246  152.81024
## 2020  224.29025  440.09690  646.45724  823.77876 1415.65499  193.26948
## 2021  190.78066  225.12346  535.54389 1199.73199 1406.42748  434.94900
##             Jul        Aug        Sep        Oct        Nov        Dec
## 2011  448.01446 1334.56541   92.18066  396.73570  385.87217  758.37575
## 2012  445.67986 1000.58272  261.36103  475.96294  392.40476  892.19571
## 2013  651.41614  444.49077  318.61750  503.10060  633.13997 1032.20846
## 2014 1415.42457  330.56652  349.73945  507.07185  479.52777  858.19636
## 2015 1404.93564  267.48039  458.42324  540.49000  665.82226  935.00464
## 2016  600.40955  310.76644  397.14109  478.93165  692.11655 1274.95161
## 2017  274.67225  722.23003  431.55757  688.71465  823.43364 1200.64251
## 2018  343.85731  554.01268  415.87756  561.26903  631.11928  953.91478
## 2019  825.93749  641.39639  462.88459  710.51746  804.34719 1001.84450
## 2020  682.30480  352.21086  694.37750  939.31635  760.47623 1049.55259
## 2021  730.85906  468.65727
Kalimantanoutflowtimeseries
##             Jan        Feb        Mar        Apr        May        Jun
## 2011   582.2242   859.0178  1570.2218  2337.0253  2019.1669  2439.1742
## 2012   834.9211  1409.7713  2125.2689  2378.9988  2628.5642  2954.4279
## 2013  1035.3895  1808.5302  2731.7646  2153.8350  3810.3190  3437.1400
## 2014   948.7785  1379.0510  2511.3898  2746.2057  2713.3284  2831.2588
## 2015   686.6159  1783.9609  2295.2388  3361.3209  3013.7731  4325.7830
## 2016   818.7089  1925.1134  2081.6134  3036.3231  3907.9318  8764.1853
## 2017  1552.3718  2485.4757  3262.4454  3459.7874  4157.8382 10832.3521
## 2018   817.5598  2849.7438  3927.9008  3676.1021  7041.7074  9637.7045
## 2019  1235.8249  2929.3173  3734.6734  5220.7579 13438.4430   856.1754
## 2020  1568.3579  2566.7644  3898.8501  5176.8640  7565.9636  1546.9692
## 2021   618.8893  2150.0993  3163.2461  6284.5272  7612.7585  3140.4786
##             Jul        Aug        Sep        Oct        Nov        Dec
## 2011  2543.5871  6258.0677   671.3997  2174.8158  2631.5086  5448.2917
## 2012  2834.8268  5112.4519  1065.1376  3006.8743  2832.1058  6260.9022
## 2013  8871.1225  4572.3990  2069.9639  3150.6647  3557.6844  7730.3153
## 2014  8509.6390  1072.7505  2499.2401  3501.1177  2882.1789  7177.1445
## 2015  7950.5142  1569.0496  2818.2509  3058.4110  3782.5731  7299.3565
## 2016  2815.3950  2328.2286  3181.5704  2887.3519  3873.3004  6559.2052
## 2017  1396.5417  4158.7154  2746.5025  3688.0760  4964.1545  7699.4466
## 2018  2665.5558  4053.4685  3024.6391  3960.9865  4382.4883  7951.2099
## 2019  4475.0908  4230.7453  3322.1716  4185.1525  4989.9148  8960.7725
## 2020  4100.4353  3203.6999  3570.6942  5348.0481  4276.5758  9237.0826
## 2021  4112.9850  3207.9518
plot.ts(KalimantanSelataninflowtimeseries,type = "l", col = "khaki")
lines(Kalimantaninflowtimeseries, type = "l", col = "sienna")
legend("top",c("KalimantanSelataninflowtimeseries","Kalimantannflowtimeseries"),fill=c("khaki","sienna"))

KalimantanSelatanintimeseriescomponents <- decompose(KalimantanSelataninflowtimeseries)
Kalimantanintimeseriescomponents <- decompose(Kalimantaninflowtimeseries)
KalimantanSelatanintimeseriescomponents$seasonal
##               Jan          Feb          Mar          Apr          May
## 2011  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2012  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2013  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2014  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2015  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2016  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2017  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2018  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2019  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2020  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2021  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
##               Jun          Jul          Aug          Sep          Oct
## 2011   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2012   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2013   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2014   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2015   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2016   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2017   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2018   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2019   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2020   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2021   34.0293887   80.1720969  410.8362816                          
##               Nov          Dec
## 2011 -198.0499023 -293.4538435
## 2012 -198.0499023 -293.4538435
## 2013 -198.0499023 -293.4538435
## 2014 -198.0499023 -293.4538435
## 2015 -198.0499023 -293.4538435
## 2016 -198.0499023 -293.4538435
## 2017 -198.0499023 -293.4538435
## 2018 -198.0499023 -293.4538435
## 2019 -198.0499023 -293.4538435
## 2020 -198.0499023 -293.4538435
## 2021
Kalimantanintimeseriescomponents$seasonal
##               Jan          Feb          Mar          Apr          May
## 2011  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2012  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2013  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2014  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2015  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2016  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2017  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2018  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2019  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2020  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
## 2021  424.6520534   -0.7561956  -31.6108601  -31.2258212  -78.5270515
##               Jun          Jul          Aug          Sep          Oct
## 2011   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2012   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2013   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2014   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2015   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2016   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2017   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2018   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2019   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2020   34.0293887   80.1720969  410.8362816 -144.8198416 -171.2463046
## 2021   34.0293887   80.1720969  410.8362816                          
##               Nov          Dec
## 2011 -198.0499023 -293.4538435
## 2012 -198.0499023 -293.4538435
## 2013 -198.0499023 -293.4538435
## 2014 -198.0499023 -293.4538435
## 2015 -198.0499023 -293.4538435
## 2016 -198.0499023 -293.4538435
## 2017 -198.0499023 -293.4538435
## 2018 -198.0499023 -293.4538435
## 2019 -198.0499023 -293.4538435
## 2020 -198.0499023 -293.4538435
## 2021
KalimantanSelatanouttimeseriescomponents <- decompose(KalimantanSelatanoutflowtimeseries)
Kalimantanouttimeseriescomponents <- decompose(Kalimantanoutflowtimeseries)
KalimantanSelatanouttimeseriescomponents$seasonal
##              Jan         Feb         Mar         Apr         May         Jun
## 2011 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2012 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2013 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2014 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2015 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2016 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2017 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2018 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2019 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2020 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
## 2021 -468.949094 -290.659144  -77.279644  -35.758681  318.594760  304.250690
##              Jul         Aug         Sep         Oct         Nov         Dec
## 2011  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2012  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2013  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2014  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2015  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2016  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2017  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2018  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2019  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2020  108.326682   -5.805776 -214.302308  -26.700598   11.920287  376.362827
## 2021  108.326682   -5.805776
Kalimantanouttimeseriescomponents$seasonal
##              Jan         Feb         Mar         Apr         May         Jun
## 2011 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2012 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2013 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2014 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2015 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2016 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2017 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2018 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2019 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2020 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
## 2021 -2825.07684 -1701.86621  -813.75865  -326.19998  1547.90126  1179.20313
##              Jul         Aug         Sep         Oct         Nov         Dec
## 2011   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2012   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2013   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2014   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2015   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2016   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2017   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2018   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2019   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2020   895.53166   -70.31379 -1241.33156  -265.22422    16.11986  3605.01535
## 2021   895.53166   -70.31379
plot(KalimantanSelatanintimeseriescomponents$seasonal,type = "l", col = "purple")
lines(Kalimantanintimeseriescomponents$seasonal,col="palegreen")
lines(KalimantanSelatanouttimeseriescomponents$seasonal, type = "l", col = "lightskyblue")
lines(Kalimantanouttimeseriescomponents$seasonal,col="orange")
legend("top",c("Kalimantan Selatan Inflow","Kalimantan Inflow", "Kalimantan Selatan Outflow","Kalimantan Outflow"),fill=c("purple","palegreen","lightskyblue","orange"))

plot(KalimantanSelatanintimeseriescomponents$trend,type = "l", col = "purple")
lines(Kalimantanintimeseriescomponents$trend,col="palegreen")
lines(KalimantanSelatanouttimeseriescomponents$trend, type = "l", col = "lightskyblue")
lines(Kalimantanouttimeseriescomponents$trend,col="orange")
legend("top",c("Kalimantan Selatan Inflow","Kalimantan Inflow", "Kalimantan Selatan Outflow","Kalimantan Outflow"),fill=c("purple","palegreen","lightskyblue","red"))

plot(KalimantanSelatanintimeseriescomponents$random,type = "l", col = "purple")
lines(Kalimantanintimeseriescomponents$random,col="palegreen")
lines(KalimantanSelatanouttimeseriescomponents$random, type = "l", col = "lightskyblue")
lines(Kalimantanouttimeseriescomponents$random,col="orange")
legend("top",c("Kalimantan Selatan Inflow","Kalimantan Inflow", "Kalimatan Selatan Outflow","Kalimantan Outflow"),fill=c("purple","palegreen","lightskyblue","orange"))

plot(KalimantanSelatanintimeseriescomponents$figure,type = "l", col = "purple")
lines(Kalimantanintimeseriescomponents$figure,col="palegreen")
lines(KalimantanSelatanouttimeseriescomponents$figure, type = "l", col = "lightskyblue")
lines(Kalimantanouttimeseriescomponents$figure,col="orange")
legend("top",c("Kalimantan Selatan Inflow","Kalimantan Inflow", "Kalimantan Selatan Outflow","Kalimantan Outflow"),fill=c("purple","palegreen","lightskyblue","blue"))