prod_ | R Documentation |
Product of a function
prod_(f, var, lower, upper, doit = TRUE)
f |
Function to take product of |
var |
Variable to take product for (either string or |
lower |
Lower limit |
upper |
Upper limit |
doit |
Evaluate the product immediately (or later with |
if (has_sympy()) {
x <- symbol("x")
p <- prod_(1/x, "x", 1, 10)
p
as_expr(p)
prod(1/(1:10))
n <- symbol("n")
prod_(x, x, 1, n)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.