alternative H1: stationary.
Reference:
https://en.wikipedia.org/wiki/Augmented_Dickey%E2%80%93Fuller_test
https://en.wikipedia.org/wiki/Stationary_process
This site is to serve as my note-book and to effectively communicate with my students and collaborators. Every now and then, a blog may be of interest to other researchers or teachers. Views in this blog are my own. All rights of research results and findings on this blog are reserved. See also http://youtube.com/c/hongqin @hongqin
two independent random walks, r=0 for Johansen test
one random walk and one stationary series, r=1 for Johansen test.
HQ realized that rank=2 for two variable is actually a good combination.
Moderate cointegration of Rt and Apple driving.
Northern states are more likely to have Rt ~ T2m
Confirmed by Rt, T2m, Apple-driving
21:30. HQ added adf.test and found many small p-value for T2m, dewpoint and even Rt. Small p-value of ADF-test means alternative hypothesis cannot be rejected. This means dewpoint are mostly stationary.
working code: _generate_tables_for_publication.Rmd
10% critical value
Rt ~T2m
a digital signature
https://comodosslstore.com/resources/what-is-an-smime-p7s-file-attachment-and-how-do-i-open-it/
running codes:
auto_county_cajo_20200915-20210215-5percent.R
auto_county_cajo_20200915-20210215-1percent.R
output files:
(base) hqin@CS313BQin COVID19_transmission_MS % ls _run-20200915-20210215/*csv
_run-20200915-20210215/_autocajo_1-3151:2020-09-15-to-2021-02-15-cval-1percent.csv
_run-20200915-20210215/_autocajo_1-3151:2020-09-15-to-2021-02-15-cval-5percent.csv
There was a typo in a variable name, which took 2-3 hours to fix.
# Function to get cajo test rank
get_cajo_rank = function( in_system, in_K= 12, in_cval_index=3, in_max_cajo_order=1 ) {
tryCatch (
{ test_tmp = ca.jo(in_system, type='trace', ecdet = 'const', K= in_K)
ratio_test_cvalPer = test_tmp@teststat / test_tmp@cval[,in_cval_index] #ratio of test statistics vs critical values
number_of_positive_tests = table( ratio_test_cvalPer > 1)['TRUE'] #return the number of TRUE, which can > max_cajo_order
output_rank = min( number_of_positive_tests, in_max_cajo_order ) # make sure max_cajo_order is the up limit
print(paste("get_cajo_rank():: output_rank = ", output_rank))
return(output_rank)
},
error=function(error_message) {
output_rank = -999 # an error code
return(output_rank)
})
}
== In-class to do:
For ECS Room 220, podium computer use channel 4 in Extron controller.
restart computer to make sure ZOOM works. make sure Bluetooth mouse are turned off.
clean up desktop space, calendars:
ZOOM, live transcript (start video recording). Turn the computer speaker on.
* college tech symposium pre-registraion, title, team members, faculty name and course number, poster. Let students work in class to pre-registrate.
* Start Ch6 socrative, went through Q11 ----last question. Next time, start with Ch7.
based on the Baker science paper, first wave is tsunami, second wave may be seasonal.
11:40 run on lambda.
ls
auto_county_cajo_2020-2021-winter.R key_output _nohup_winter_peak_lambda.txt
(base) hqin@ECS323Lambda:~/COVID19_transmission_MS/_run-2020-2021-winter-peak$ nohup R -f auto_county_cajo_2020-2021-winter.R > _nohup_winter_peak_lambda.txt &
[1] 72501
This run very fast
5pm. Went through output '_autocajo_1-3151/2020-09-01-to-2021-05-01. csv', and found many counties do not have no google mobility values.
All counties of Louisiana has NA google mobility. This might be a bug in my code. TODO
So, I need to redo analysis with Rt- t2m, Rt-dewpoint, Rt ~A_driving.
add Rt ~ mobility + weather test result to batch output.
/Users/hqin/github/COVID19_transmission_MS
14:40 bug found. There are two dataframes, location and report, but with different rows. Correct the bug with using report consistently.
bug found when cajo. Rt ~ g_workplace
Hardeman | Tennessee | 47069 | 35.2077202 | -88.991612 | TRUE | TRUE | date::era5_t2m::era5_dewpoint::dailyCases::Rt::A_driving::g_retail::g_grocery::g_parks::g_transit::g_workplace::g_residential | 2 |
There are only 2 variable, how did rank of 2 returned?
Eigenvalues (lambda):
[1] 0.06519351 0.04638336 0.00000000
Values of teststatistic and critical values of test:
test 10pct 5pct 1pct
r <= 1 | 21.51 7.52 9.24 12.97
r = 0 | 52.05 17.85 19.96 24.60
So, the return is correct numerically.
report$order_cajo_gworkplace[i] = table( ratio_test_cval1Per > 1)['TRUE'] #return the number of TRUE, which
# give 2 sometimes for 1 pair ca.jo test
have the courage to take your own thoughts seriously.
Tim Chartier, Davidson College.
turn off Spotlight search for GoogleDrive and OneDrive
In settings, locate "Spotlight", then add Google Drive and OneDrive directories into "privacy".
Referece:
== In-class to do:
For ECS Room 220, podium computer use channel 4 in Extron controller.
restart computer to make sure ZOOM works. make sure Bluetooth mouse are turned off.
clean up desktop space, calendars:
ZOOM, live transcript (start video recording). Turn the computer speaker on.
* Start Ch6 socrative, went through Q1-10.
11:15-> let teams work on projects.
== pre-class to do:
calendar email invitation: including guests; NA
socrative questions. done
update Canvas course materials, update learning objectives. assignments as needed. NA
* make sure grades are NOT shown on Canvas.
learning objectives: ??
== In-class to do:
For ECS Room 220, podium computer use channel 4 in Extron controller.
restart computer to make sure ZOOM works. make sure Bluetooth mouse are turned off.
clean up desktop space, calendars:
ZOOM, live transcript (start video recording). Turn the computer speaker on.
* socrative, Ch5. start at "Q 16" - finished Ch5in 30 minutes.
*go over team project, let student work on Product backlog and Spring 1 plan.