Yes, definitely. However, this is so close to being legal R code that I feel 
you have not made any effort to translate it yourself, and this is the "R-help" 
mailing list, not the "R-do-my-work-for-me" mailing list. Is this homework?  
Have you read the "Introduction to R" document that is supplied with R? There 
are also many basic tutorials on the Internet and books available that would 
discuss the need to write R statements in an appropriate  order so later 
statements can use objects created by earlier statements.
-- 
Sent from my phone. Please excuse my brevity.

On July 6, 2017 8:14:19 AM PDT, Marine Regis <marine.re...@hotmail.fr> wrote:
>Hello,
>
>Is it possible to generate simulated data that look like the attached
>figure?
>
>The curve in the figure can be obtained from this equation respecting
>some conditions:
>
>
>
>if(Temperature > T_min & Temperature < T_max){
>
>   a*( Temperature -T_min)*( Temperature -T_max)
>
>} else 0
>
>
>T_min ~ Uniform(0, 24)
>
>T_max ~ Uniform(25, 45)
>
>-a ~ Gamma(1, 1)
>
>Temperature <- seq(0, 45, by = 1)
>
>
>
>Thank you very much for your help.
>
>Have a nice day
>
>Marine

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to