Dear moderators, I am a student come from Lanzhou University, Gansu, China. I have two questions on R (mgcv), which puzzled me for a long time. I did not find answer in Chinese forum. I hope you could answer me in your free time or post it in R-help. Thank you very much. Xuping Song 2016.11.11 We want to investigate the association between exposure to ambient temperature and blood pressure. The ?mgcv? package was used to perform GAM analyses in R. This is the formula. ct=gam(Blood pressure~s(Temp,k=5)+s(BMI,k=4)+s(Age,k=6)+s(RH,k=4)+s(Pa,k=5)+Gender+Season,family=gaussian,data=mydata) I have two questions. Firstly, personal characteristic (Age, Gender, BMI and Season) could influence blood pressure. How to control these variables? BMI and Age are continuous variable. I smoothed these two variables like formula 1. Season (1,2,3,4) and Gender(0,1) were add to formula, which were assumed as linear relationship. Is that right? Secondly, I want to get plot 2, which x-axis presented ?Temperature? and y-axis presented ?Change in Blood Pressure for every 1?C decrease of temperature?. Plot 2 came from a paper published recently (see appendix). Therefore, I ran formula 1 in R and run ?plot(ct)?. Then I get plot 1. I don?t understand the meaning of ?s?Tmean?3.87?? in y-axis. Does it represent ?Blood pressure?? If the hypothesis is right, plot 2 is the derivative of plot 1. However, I don?t know the specific code. I am a beginner of R and this problem puzzled me for a long time. Please help me. Thank you very much. -------------- next part -------------- A non-text attachment was scrubbed... Name: Paper (plot 2).pdf Type: application/pdf Size: 913655 bytes Desc: not available URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20161111/4c9d7aec/attachment-0001.pdf> -------------- next part -------------- A non-text attachment was scrubbed... Name: Plot 2.png Type: image/png Size: 37455 bytes Desc: not available URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20161111/4c9d7aec/attachment-0001.png>