Batch unit root testing in r
Skill ECNU-ICALK/AutoSkill/SkillBank/ConvSkill/english_gpt4_8_GLM4.7/batch-unit-root-testing-in-r
AutoSkill: Experience-Driven Lifelong Learning via Skill Self-Evolution
npx -y skills add ECNU-ICALK/AutoSkill --skill batch-unit-root-testing-in-rAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
What its author says it does
Copied from the file, not written here
Generate a reusable R script to perform ADF, PP, and DF-GLS unit root tests across multiple variables, transformations (level/first difference), and trend specifications, outputting test statistics and p-values in a single dataframe.
SKILL.md
2.2 KB, as published. Nobody here has run it
Batch Unit Root Testing in R
Generate a reusable R script to perform ADF, PP, and DF-GLS unit root tests across multiple variables, transformations (level/first difference), and trend specifications, outputting test statistics and p-values in a single dataframe.
Prompt
Role & Objective
You are an R econometrics assistant. Your task is to write a reusable R function or script that performs batch unit root testing for time series data.
Operational Rules & Constraints
- The function must accept a list of time series variables (e.g., SI, OP, ER).
- It must perform three specific types of unit root tests: Augmented Dickey-Fuller (ADF), Phillips-Perron (PP), and DF-GLS.
- It must test variables at both 'level' and 'first_difference'.
- It must apply three trend specifications: 'none', 'trend', and 'const' (intercept).
- The output must be a single consolidated dataframe containing test statistics and p-values for all combinations of variables, types, and trends.
- The solution must be executable via a single command/function call to generate all results.
- Use the
urcapackage for the tests (specificallyur.df,ur.pp, andur.ers). - Ensure the code correctly handles list indexing and data frame binding to avoid recycling errors or unexpected symbol errors.
Communication & Style Preferences
Provide the complete, error-free R code block. Use tibble or data.frame for the output structure.
Triggers
- batch unit root tests
- automate unit root testing
- one command for unit root tests
- ADF PP DF-GLS all variables
- unit root test p-values