Hello Everyone,
I'm Kousay, and I'm conducting research on the impact of the pandemic on the firm financial performance. To represent the firm's total financial performance, I have chosen several variables. Still, as I am unable to add them, I need to generate a new variable called "score" in Stata using the following commands. However, when I run the last command, I encounter an error code (198). I have already checked all the variables and ensured there are no missing values and verified the spelling, but I still can't locate this new variable score. I hope to receive some help as this is the dependent variable for my regression.
following are the command Im using
// Define weights for each variable
local weights "0.2 0.3 0.2 0.2 0.1"
// Define variables to include in the analysis
local variables "ROA ROE EPS earnings_growth revenue_growth"
// Generate a new variable as the weighted sum of the selected variables
egen score = rowtotal ROA ROE EPS earnings_growth revenue_growth /wordcount ROA ROE EPS earnings_growth revenue_growth/ 5 * 0.2 0.3 0.1 0.2 0.2
this last step to generate the new variable score, I get this error r(198)
If anyone has any suggestions on what might be causing this error or any tips on how to fix it, please let me know. I would greatly appreciate any help you can offer!
Thank you in advance.
Related Posts with Error Code (199)
Diff-in-diff collinearity problem with leads and lagsDear Statlist users, This is my first post so I hope I've done everything according to Statalist pr…
Interaction term with individual in FEHello! I have a following question: I want to estimate the impact of increased use of computers by …
Converting Variables to a dummy variableHello, Actually I have three variables in percentage (Formal credit - semi-formal credit - Informal …
Invalid name errorSo I am trying to upload a .csv file into Stata, but when I run it, it gives me an 'Invalid name' er…
new ASA "statement" re: p-valuesas has been discussed in this Forum in the past, the ASA previously issued a statement attempting to…
Subscribe to:
Post Comments (Atom)
0 Response to Error Code (199)
Post a Comment