I need to make transformation for x7 in my model
what sas code should i write to do that
my model should be y=x1 x2 x3 x4 x5 exp(x7) x8 x9 x10
You create a new variable in a data step that has the value exp(x7), and then in PROC REG or PROC GLM you use this new variable (and any other variables of interest) in the model.
@shahd wrote:
I did that but still have error
We need to know what ERROR. Show us the SAS log. Click on the {i} icon and paste the SAS log into that window.
What you showed us is not code. It is missing semi-colons and the word PROC and possibly other stuff. Don't show us made up code. Show us the actual code that you used. Click on the "running man" icon and paste the actual code into that window.
It doesn't seem like you did anything close to what I explained in my message earlier in the thread, where I specifically said you should create a new variable in a data step.
So, next time I am going to be picky. Please click on the running man icon (if you hold your mouse over the icon, it says "Insert SAS Code") and then paste your code into that window.
You also need to show us the SAS log, which I believe if you look at it (rather than I look at it), you will see the error clearly. Click on the {i} icon and paste your code into that window.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.