An edit of the lhsnorm function can probably answer your question. In matlab: edit lhsnorm: function X,z = lhsnorm(mu,sigma,n,dosmooth)%LHSNORM Generate a latin hypercube sample with a normal distribution% X=LHSNORM(MU,SIGMA,N) generates a latin hypercube sample X of size% N from the multivariate normal distribution with mean vector MU% and covariance matrix SIGMA. X is similar to a random sample from% the multivariate normal distribution, but the marginal distribution% of each column is adjusted so that its sample marginal distribution% is close to its theoretical normal distribution.%% X=LHSNORM(MU,SIGMA,N,'ONOFF') controls the amount of smoothing in the% sample. If 'ONOFF' is 'off', each column has points equally spaced% on the probability scale. In other words, each column is a permutation% of the values G(.5/N), G(1.5/N)., G(1.5/N) where G is the inverse% normal cumulative distribution for that column's marginal distribution.% If 'ONOFF' is 'on' (the default), each column has points uniformly% distributed on the probability scale. For example, in place of% 0.5/N we use a value having a uniform distribution on the% interval (0/N,1/N).%% X,Z=LHSNORM(.) also returns Z, the original multivariate normal% sample before the marginals are adjusted to obtain X.%% See also LHSDESIGN, MVNRND.% Reference: Stein, M. Large sample properties of simulations% using Latin hypercube sampling.
X = lhsdesign(n,p) returns an n-by-p matrix, X, containing a latin hypercube sample of n values on each of p variables. For each column of X, the n values are randomly distributed with one from each interval (0,1/n). Run the command by entering it in the MATLAB Command Window. Latin Hypercube sampling. Each variable range divided into ny. Latin Hypercube definition matrix. For n points with m. Matlab lhsdesign.
Technometrics, 29, 143-151. Correction,% 32, 367.% Copyright 1993-2010 The MathWorks, Inc.% $Revision: 1.1.8.1 $ $Date: 2010/03/16 00:15:10 $% Generate a random sample with a specified distribution and% correlation structure - in this case multivariate normal z = mvnrnd(mu,sigma,n);% Find the ranks of each column p = length(mu); x = zeros(size(z),class(z)); for i=1:p x(:,i) = rank(z(:,i)); end% Get gridded or smoothed-out values on the unit interval if (nargin.
Description X = lhsnorm(mu,sigma,n) returns an n-by- p matrix, X, containing a latin hypercube sample of size n from a p-dimensional multivariate normal distribution with mean vector, mu, and covariance matrix, sigma. X is similar to a random sample from the multivariate normal distribution, but the marginal distribution of each column is adjusted so that its sample marginal distribution is close to its theoretical normal distribution. X = lhsnorm(mu,sigma,n, flag) controls the amount of smoothing in the sample. If flag is 'off', each column has points equally spaced on the probability scale. In other words, each column is a permutation of the values G(0.5/n), G(1.5/n)., G(1-0.5/n), where G is the inverse normal cumulative distribution for that column's marginal distribution. If flag is 'on' (the default), each column has points uniformly distributed on the probability scale.
![Latin hypercube method Latin hypercube method](/uploads/1/2/5/5/125561310/347470687.png)
For example, in place of 0.5/n you use a value having a uniform distribution on the interval (0/n,1/n). X,Z = lhsnorm(.) also returns Z, the original multivariate normal sample before the marginals are adjusted to obtain X.