function factory( k, lambda ) {
	if (
		isnan( k ) ||
		isnan( lambda ) ||
		k <= 0.0 ||
		lambda <= 0.0
	) {
		return constantFunction( NaN );
	}
	return pdf;

	/**
	* Evaluates the probability density function (PDF) for a Weibull distribution.
	*
	* @private
	* @param {number} x - input value
	* @returns {number} evaluated PDF
	*
	* @example
	* var y = pdf( 2.3 );
	* // returns <number>
	*/
	function pdf( x ) {
		var xol;
		var z;
		if ( x < 0.0 ) {
			return 0.0;
		}
		if ( x === PINF || x === NINF ) {
			return 0.0;
		}
		if ( x === 0.0 ) {
			return ( k === 1.0 ) ? k / lambda : 0.0;
		}
		xol = x / lambda;
		z = pow( xol, k - 1.0 );
		return ( k / lambda ) * z * exp( -pow( xol, k ) );
	}
}
Returns a function for evaluating the probability density function (PDF) for a Weibull distribution.

@param {PositiveNumber} k - shape parameter
@param {PositiveNumber} lambda - scale parameter
@returns {Function} function to evaluate the probability density function

@example
var pdf = factory( 7.0, 6.0 );
var y = pdf( 7.0 );
// returns ~0.155

y = pdf( 5.0 );
// returns ~0.296