root/applications/bdmtoolbox/mex/epdf_1dplot.m @ 856

Revision 803, 451 bytes (checked in by smidl, 15 years ago)

new wrappers in bdmtoolbox + display functions

Line 
1function epdf_1dplot(pdf,xlims, points)
2% function evaluates given pdf on support
3%  xlims = [x_begin, x_end] --or-- empty
4%  points = if not given, 100
5
6if nargin<3
7    points = 100;
8end
9
10if nargin<2 | isempty(xlims)
11    p_mean = epdf_mean(pdf);
12    p_var  = epdf_variance(pdf);
13    xlims = p_mean(1)*[1 1] + [-3 3]*sqrt(p_var(1));
14end
15
16steps = [xlims(2)-xlims(1)];
17x = xlims(1):steps/(points-1):xlims(2);
18v = epdf_evallog_mat(pdf,x);
19plot(x,exp(v));
Note: See TracBrowser for help on using the browser.