Displaying 20 results from an estimated 230 matches for "inequality".
2013 Mar 19
0
linear model with equality and inequality (redundant) constraints
Dear R-users,
in the last days I have been trying to estimate a normal linear model with equality and inequality constraints.
Please find below a simple example of my problem.
Of course, one could easily see that, though the constraints are consistent, there is some redundancy in the specific constraints. Nevertheless my actual applications can get much larger and I would not like to manually check for pre...
2011 Sep 08
3
global optimisation with inequality constraints
Dear All,
I would like to minimise a nonlinear function subject to linear inequality constraints as part of an R program. I have been using the constrOptim function. I have tried all of the methods that come with Optim, but nothing finds the correct solution. If I use the correct solution as the vector of starting values, though, my program does output the correct solution and o...
2012 Oct 19
2
Which package/function for solving weighted linear least squares with inequality and equality constraints?
Dear All,
Which package/function could i use to solve following linear least square
problem?
A over determined system of linear equations is given. The nnls-function may
would be a possibility BUT:
The solving is constrained with
a inequality that all unknowns are >= 0
and a equality that the sum of all unknowns is 1
The influence of the equations according to the solving process is weighted
too.
llAx-bll2 * weight
with xi >=0 and sum(x)=1
I?m pleased about every suggestion.
Thank you and best regards
Thomas
--
View this...
2003 Sep 26
1
least squares regression using (inequality) restrictions
...rs,
I would like to make a lesast squares regression similar to that what is
done by the command "lm". But additionally, I would like to impose some
restrictions:
1) The sum of all regression coefficients should be equal to 1.
2) Each coefficient should assume a value between 0 and 1. (inequality
restrictions)
Which command is the best to use in order to solve this problem in a
computationally efficient way?
Thank you in advance for your help,
Harald Bartel
--
------------------------------------------------------
PROZENTOR GmbH
Financial Content Provider
Bergstr. 67
10115 Berlin
Fon...
2011 Jul 10
1
Chebyshev Inequality — MVUE
Hello,
I was interested in trying to write an R script to calculate a UCL for a lognormal distribution using the Chebyshev Inequality — MVUE Approach (based on EPA’s guidance found in http://www.epa.gov/oswer/riskassessment/pdf/ucl.pdf). This looks like it should be straight forward, but I am need to calculate an MVUE for the population mean and an MVUE for the population variance, which requires a value (g_n) from a table A7, f...
2010 Jan 21
1
Double inequality with plotmath
Hello,
I'm fairly new to R and I can't work out how to produce a double
inequality like (LaTeX) $0 \leq x \leq 1$ in the legend of a graph. If
I try
> legend(50, 0.1, legend = c(expression(0 <= x <= 1), c(2 <= x <= 3)), pch = c(1,1), col = c(2, 3))
then I get an error message "unexpected '<=' in ...". I've checked the
help files for plotm...
2008 Dec 28
1
Logistic regression with rcs() and inequality constraints?
Dear guRus,
I am doing a logistic regression using restricted cubic splines via
rcs(). However, the fitted probabilities should be nondecreasing with
increasing predictor. Example:
predictor <- seq(1,20)
y <- c(rep(0,9),rep(1,10),0)
model <- glm(y~rcs(predictor,n.knots=3),family="binomial")
print(1/(1+exp(-predict(model))))
The last expression should be a nondecreasing
2008 Jul 29
0
optimize simultaneously two binomials inequalities using nlm
Dear R users,
I?m trying to optimize simultaneously two binomials inequalities used to
acceptance sampling, which are nonlinear solution, so there is no simple
direct solution. Please, let me explain shortly the the problem and the
question as following.
The objective is to obtain the smallest value of 'n' (sample size)
satisfying both inequalities:
(1-alpha) <= pbinom(c, n, p1)
2006 Aug 17
2
dovecot on OSF/1 4.0
...ix/sh ../../depcomp cc -std -DHAVE_CONFIG_H
-I. -I. -I../.. -I/usr/pkg/include -ieee -O2 -I/usr/pkg/include -
I/usr/pkg/include -c file-cache.c
cc: Error: file-cache.c, line 70: In this statement, "cache-
>mmap_base" and "(-1)" may not be compared for equality or inequality.
if (cache->mmap_base == MAP_FAILED) {
--------------------^
cc: Error: file-cache.c, line 79: In this statement, "cache-
>mmap_base" and "(-1)" may not be compared for equality or inequality.
if (cache->mmap_base == MAP_FAILED) {
---...
2008 Aug 05
1
optimize simultaneously two binomials inequalities using nlm( ) or optim( )
Dear R users,
I?m trying to optimize simultaneously two binomials inequalities (used in
acceptance sampling) which are nonlinear solution, so there is no simple
direct solution. Please, let me explain shortly the the problem and the
question as following.
The objective is to obtain the smallest value of 'n' (sample size)
satisfying both inequalities:
(1-alpha) <= pbinom(c, n, p1)
2006 Sep 22
2
inequality with NA
Dear everybody!
take a<-c(5,3,NA,6).
if(a[1]!=NA){b<-7}
if(a[3]!=5){b<-7}
if(a[3]!=NA){b<-7}
if(a[3]==NA){b<-7}
will alltogeather return
Fehler in if (a[1] != NA) { : Fehlender Wert, wo TRUE/FALSE n?tig ist
(or simularly). Somehow this is logical. But how else should I get out,
whether a certain vector-component has an existing value?
Thank you in advance!
Yours,
Mag. Ferri
2017 Oct 06
1
Help in R package
Hello,
I watched your YouTube videos for explanation for R package. They are
really helpful for new beginner for using R. Please I need your help for
solving inequalities that contain beta functions using R studio. I attached
the file that contains this inequalities.
I appreciate your help and looking forward to hear from you.
Akram
-------------- next part --------------
A non-text attachment
2012 May 08
1
Translation of Linear minimization probelm from matlab to r
...on problem from Matlab into r.
The matlab code is as follow:
options = optimset('Diagnostics','on');
[x fval exitflag] = linprog(f,A,b,Aeq,beq,lb,ub,[],options);
exitflag
fval
x=round(x);
Where:
f = Linear objective function vector (vector of 45,rows)
A = Matrix for linear inequality constraints (3colums 45 rows matrix)
b = Vector for linear inequality constraints (3 rows vector)
Aeq = Matrix for linear equality constraints (45 colums, 8 rows )
beq = Vector for linear equality constraints (8 rows vector)
lb =Vector of lower bounds (45 rows)
ub = Vector of upper bounds (...
2010 Nov 04
5
Logical vectors
Hi folks,
Pls help me to understand follow;
An Introduction to R
2.4 Logical vectors
http://cran.r-project.org/doc/manuals/R-intro.html#R-and-statistics
1)
> x
[1] 1 2 3 4 5
> temp <- x != 1
> temp
[1] FALSE TRUE TRUE TRUE TRUE
>
2)
> x
[1] 1 2 3 4 5
> temp <- x > 1
> temp
[1] FALSE TRUE TRUE TRUE TRUE
Why NOT
> temp
[1] TRUE FALSE FALSE FALSE
2010 Nov 04
5
Logical vectors
Hi folks,
Pls help me to understand follow;
An Introduction to R
2.4 Logical vectors
http://cran.r-project.org/doc/manuals/R-intro.html#R-and-statistics
1)
> x
[1] 1 2 3 4 5
> temp <- x != 1
> temp
[1] FALSE TRUE TRUE TRUE TRUE
>
2)
> x
[1] 1 2 3 4 5
> temp <- x > 1
> temp
[1] FALSE TRUE TRUE TRUE TRUE
Why NOT
> temp
[1] TRUE FALSE FALSE FALSE
2005 Nov 28
3
optimization with inequalities
I have to estimate the following model for several
group of observations :
y(1-y) = p[1]*(x^2-y) + p[2]*y*(x-1) + p[3]*(x-y)
with constraints :
p[1]+p[3] >= 1
p[1]+p[2]+p[3]+1 >= 0
p[3] >= 0
I use the following code :
func <- sum((y(1-y) - p[1]*(x^2-y) + p[2]*y*(x-1) +
p[3]*(x-y))^2)
estim <- optim( c(1,0,0),func, method="L-BFGS-B" ,
lower=c(1-p[3], -p[1]-p[3]-1,
2004 Jul 16
1
strucchange: breakpoints in inequally spaced data
Hello,
we want to identify breakpoints (different phases) in environmental
data, algae cell counts of three years with intervals between 7 and 30
days (N=40). We found that
breakpoints(cells ~1)
works great and identifies 5 very good breaks, however we are uncertain
about these, because the data are unequally spaced. Is there a way to
include the information about the measurement intervals,
2009 Jul 17
0
Inequality constraints in GMM estimation?
I have a relatively simple finance application of GMM. Given the moment
condition:
E[m*R]=0
where m=m[theta]
I would like to constrain m>0. Any ideas?
[[alternative HTML version deleted]]
2011 Dec 12
0
Rsolnp package: warning messages
Dear,
I am using the solnp command (package Rsolnp) for a problem with
equality and inequality constraints.
I am not getting convergence for my problem but apart that I get 1
warning per iteration saying: ?In cbind(temp, funv) : number of rows
of result is not a multiple of vector length (arg 1)?.
I checked for equality and inequality functions and they seem fine to
me. Where this mes...
2012 Jul 12
0
Enforcing inequality bounds and heteroscedasticity in a GAM or GLM
I have a spatial salinity field s and a model g(s) ~ Xb where the X comes from slightly modified GAM basis functions.
I am trying to deal with the following set of requirements:
1. The underlying physics are linear, and plain salinity (the identity link) is the correct response to my covariates.
2. Dispersion (variance or sd) is almost certainly proportional to the mean.
3. The data s(x,y)