# R script for to make a plot of a function and demonstrate # calling procedures from separate files. # The code in this file is a procedure that evaluates the function and ... # return the value to the calling procedure. # http://www.math.nyu.edu/faculty/goodman/teaching/MathFin/index.html # Author: Jonathan Goodman mod_wave = function( x, k) { phase = k*x ans = x*sin( phase) ans }