Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

How to generate Latin Hypercube parameter space

1,906 views
Skip to first unread message

Md. Shahriar Karim

unread,
Apr 20, 2010, 1:18:06 PM4/20/10
to
Can anybody help me in generating a latin hypercube parameter space? I plan to use 6 variables with 4 different values of each. Is there any matlab function that can do all the tricks?

I saw "lhsdesign (n, p)", but not sure how to utilize that for my parameter range. Thanks,

James Allison

unread,
Apr 20, 2010, 4:06:19 PM4/20/10
to
You can always rescale lhsdesign output from [0 1] to another range. For
example, if lb and ub specify the lower and upper bounds for each
parameter, try:

lb = [-10 0 0 10 100 0]; % lower bound
ub = [10 1 10 20 500 5]; % upper bound
n = 4; % number of samples
p = 6; % number of parameters
xn = lhsdesign(n,p); % generate normalized design
x = bsxfun(@plus,lb,bsxfun(@times,xn,(ub-lb)))

-James

Maninder

unread,
Feb 22, 2013, 4:12:15 AM2/22/13
to
Hi James,
I wanted to use lhsdesign for producing parameter space within bounds and having certain constraints. I understand how to generate within given bounds through your reply but I am not able to impose the constraints on lhsdesign and the documentation of lhsdesign says nothing about constraints.
I would really appreciate if you or someone else might answer my question.
Thanks a lot.


James Allison <james....@mathworks.com> wrote in message <hql1fr$red$1...@fred.mathworks.com>...

Tom Lane

unread,
Feb 22, 2013, 4:59:39 PM2/22/13
to
It sounds like you are hoping for an extension of latin hypercube designs to
non-rectangular regions. If such a thing exists, I'm not aware of it.

Would it be satisfactory to discard the points that violate the constraints?
You might have to experiment with different sample sizes to get the desired
number of acceptable points.

-- Tom

"Maninder " <m.khu...@gmail.com> wrote in message
news:kg7cpf$1kk$1...@newscl01ah.mathworks.com...

Maninder

unread,
Feb 25, 2013, 5:37:07 AM2/25/13
to
Hi Tom,
Thanks for the reply. I am just discarding those points or just changing those parameters which cause the constraint violation.
Actually I want to use latin hypercube sampling for creating ANFIS based surrogate model. I am now facing troubles with that as I have a multi-input/multi-output system.Would you by any chance have experience with that?
Thanks again.
"Tom Lane" <tl...@mathworks.com> wrote in message <kg8pob$lv0$1...@newscl01ah.mathworks.com>...

Tom Lane

unread,
Feb 25, 2013, 10:08:35 AM2/25/13
to
> Hi Tom,
> Thanks for the reply. I am just discarding those points or just changing
> those parameters which cause the constraint violation. Actually I want to
> use latin hypercube sampling for creating ANFIS based surrogate model. I
> am now facing troubles with that as I have a multi-input/multi-output
> system.Would you by any chance have experience with that?

No, don't know anything about this.

Palak Maheshwary

unread,
Jan 5, 2015, 11:32:55 AM1/5/15
to
On Tuesday, April 20, 2010 7:18:06 PM UTC+2, Md. Shahriar Karim wrote:
> Can anybody help me in generating a latin hypercube parameter space? I plan to use 6 variables with 4 different values of each. Is there any matlab function that can do all the tricks?
>
> I saw "lhsdesign (n, p)", but not sure how to utilize that for my parameter range. Thanks,

I understand the above part but how can i modify this if i have to minimize the correlation between my parameters? Can u suggest something









Julienne LaChance

unread,
Feb 9, 2015, 10:24:17 AM2/9/15
to

It looks like the function lhsdesign has a parameter just for this. Try:

X = lhsdesign(n, p, 'criterion', 'correlation')

Check out the documentation on that same page:
http://www.mathworks.com/help/stats/lhsdesign.html

What kinds of constraints do you have that you need to eliminate points within the parameter bounds?

-Julie

Palak Maheshwary <palakmah...@gmail.com> wrote in message <d16fff63-ee75-4481...@googlegroups.com>...

MiMo Sfahani

unread,
May 12, 2016, 12:56:09 AM5/12/16
to
Is it the same solution when the variables themselves are types of different distributions? I have variables with uniform, normal and lognormal distributions. Would you please advise how can I perform LHS in this case?

Thanks and regards,
Mimo

James Allison <james....@mathworks.com> wrote in message <hql1fr$red$1...@fred.mathworks.com>...
0 new messages