I want to use FOR LOOP to find i in this equation "pbinom(0.975,30,i) =4" i range from 0 to 1.
Thank you very much !!!
Do it then.
Are you coming across a problem? Post the code and an error. Also check out the purrr
package.
i
is a probability; so it must be between 0 and 1.
A loop isn't needed
vector_of_probabilities <- seq(0.1:0.4, by = 0.1)
pbinom(q = 0.975, size = 10, p = vector_of_probabilities)
#> [1] 0.3486784401 0.1073741824 0.0282475249 0.0060466176 0.0009765625
#> [6] 0.0001048576 0.0000059049 0.0000001024 0.0000000001 0.0000000000
1 Like
This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.
If you have a query related to it or one of the replies, start a new topic and refer back with a link.