similar to: grid 4.0 generates wrong results when adding two complex units by sum()

Displaying 20 results from an estimated 1000 matches similar to: "grid 4.0 generates wrong results when adding two complex units by sum()"

2020 May 19
2
Graphic parameters with length zero in grid cause R to crash
Hi, I found in grid package, if the graphic parameters have zero length, R crashes. In the following code, I only tested `grid.rect()` and the `fill` parameter, but I think it should be similar as other grid graphic functions. In `gpar()` function, the graphic parameters are not allowed to have zero length, but we can make them with zero length by first generating a `gpar` object and then
2003 Oct 29
1
grid: dividing units by numbers
How can I divide a unit by an number or average a vector of units, e.g.: u1 <- unit( 3, 'npc' ) u2 <- unit( 6, 'npc' ) u1 / 2 ( u1 + u2 ) / 2 mean( unit.c(u1,u2) ) I would use that e.g. to to calculate the coordinates of the midpoint of a line. Wolfram
2020 Jun 12
3
tcltk image reading problem (on a mac?): [tcl] encountered an unsupported criticial chunk type "eXIf"
I don't know what has changed with Catalina But I just tried my tk console from the shell command tkcon And got the following error. Here is my shell: $ tkcon dyld: Library not loaded: /usr/local/lib:/opt/X11/lib/libtk8.6.dylib Referenced from: /usr/local/bin/wish Reason: image not found Abort trap: 6 I don't know whether this is a red herring or not, but the
2011 Mar 29
5
Integration with variable bounds
If this is posted elsewhere I cannot find it. I need to perform multiple integration where some of the variables are in the bounds of the other variables. I was trying to use R2Cuba function but cannot set the upper and lower bounds. My code so far is : int <- function(y){ u2 = y[1] z2 = y[2] u1 =y[3] z1 = y[4] ff <- u1*(z1-u1)*u2*(z2-u2)*exp(-0.027*(12-z2)) return(ff) }
2007 Mar 27
7
Replacement in an expression - can't use parse()
Dear all, Suppose I have a very long expression e. Lets assume, for simplicity, that it is e = expression(u1+u2+u3) Now I wish to replace u2 with x and u3 with 1. I.e. the 'new' expression, after replacement, should be: > e expression(u1+x+1) My question is how to do the replacement? I have tried using: > e = parse(text=gsub("u2","x",e)) > e =
2020 Jun 11
4
tcltk image reading problem (on a mac?): [tcl] encountered an unsupported criticial chunk type "eXIf"
Hello everyone I am not sure when this appeared (sometime post R 3.5.0 and after I switched to Mac OS Catalina). I do not think it happens on all platforms (e.g. seems to work on windows). But it seems that tkimage.create() no longer works on a Mac for all png files. (It does work for *some* old png files I have on disk but I have not been able to determine what is different about the
2006 Nov 21
2
Symbolic derivation using D in package stats - how do I properly convert the returned call into a character string?
Dear all, I am using the function 'D' in the 'stats' package to perform symbolic derivation. This works very well and it is much faster than e.g. Mathematica (at least for my purposes). First, I would like to thank the development team for this excellent function. However, I run into trouble in some cases, particularly when I am to do some operations on long expressions
2009 Feb 05
1
optimal control, maximization with several variables?
Dear all, I would like to solve the following problem, which can be done with optimal control theory or dynamic programming: max(x,y) a*u1+b*u2+c*f1(u2) s.t. 0<u1<x, 0<u2<f2(x,u2), x'=f3(u1,u2,x) which can be rewritten if optimal control theory should be applied as H=a*u1+b*u2+c*f1(u2)+lambda*(x') s.t. 0<u1<x, 0<u2<f2(x,u2) The maximum principle
2018 Mar 11
4
subsetting comparison problem
Hello All, I am facing a unique problem and am unable to find any help in R help pages or online. I will appreciate your help for the following problem: I have 2 data-frames, samples below and there is an expected output R Dataframe1: C1 C2 C3 C4...... CN R1 0 1 0 1 R2 1 0 1 1 R3
2011 Sep 11
3
(no subject)
Dear all, Can anyone take a look at my program below? There are two functions: f1 (lambda,z,p1) and f2(p1,cl, cu). I fixed p1=0.15 for both functions. For any fixed value of lambda (between 0.01 and 0.99), I solve f1(p1=0.15, lambda=lambda, z)=0 for the corresponding cl and cu values. Then I plug the calculated cl and cu back into the function f2. Eventually, I want to find the lambda value
2016 Dec 07
4
You have not permission to view content of this location
OS: CentosOS 7 I have installed samba + openldap + smbldap-tools + pam by: yum --enablerepo=extras install -y epel-release yum install -y smbldap-tools yum install -y samba openldap openldap-clients openldap-servers migrationtools yum install -y nss-pam* I know that smbldap-tools is a dead project, but I'm interested in it and would like research on it. I create users and
2012 Dec 06
1
Anomalous outputs from rbeta when using two different random number seeds
Hi, in the code below, I am drawing 1000 samples from two beta distributions, each time using the same random number seed. Using set.seed(80) produces results I expect, in that the differences between the distributions are very small. Using set.seed(20) produces results I can't make sense of. Around half of the time, it behaves as with set.seed(80), but around half of the time, it behaves
2013 May 16
2
A function that can modify an object? Or at least shows principles how to modify an object?
Hi, If I have an R object UUU, where the second element is U2, based on "g" column of my.table my.table of UUU is: mmm ggg gindex map Info aaa123 U1 1 1 1 aaa124 U1 1 2 1 bbb1378 U2 2 1 1 bbb8888 U2 2 2 0 bbb1389 U2 2 3
2012 Apr 24
2
Some Help Needed
Dear all, I need to do some calculation where the code used are below. I get error message when I choose k to be large, say greater than 25. The error message is "Error in integrate(temp, lower = 0, upper = 1, k, x, rho, m) : the integral is probably divergent". Can anyone give some help on resolving this. Thanks. Hannah m <- 100 alpha <- 0.05 rho <- 0.1 F0
2010 Oct 06
4
loop in R
Dear all, I need to do a loop in R, but I am not sure the software is generating "n" times the variables I request differently. When I ask to print the last matrix created, I just can see the loop for n=1. To be more precise, supose I need to simulate 10 times one variable and I want to fit the 10 variables simulated in a matrix. I dont really know what I am doing wrong, but I just
2006 Oct 30
4
Architecture for Asterisk
Dear all, I've recently installed Asterisk and am trying to understand where exactly Asterisk 'fits' in my VOIP architecture. Can/does Asterisk work as a proxy? (or only as a register server?) I am specifically interested in SIP. Could anyone perhaps point me out to a diagram with SIP users and Asterisk to better understand how I should set up my network? Thank you
2020 Jun 11
0
tcltk image reading problem (on a mac?): [tcl] encountered an unsupported criticial chunk type "eXIf"
Dear Wayne and Peter, FWIW, I observe exactly the same problem in Catalina. The error and my session info: -------- snip -------- > tkimage.create("photo", file = fname) Error in structure(.External(.C_dotTclObjv, objv), class = "tclObj") : [tcl] encountered an unsupported criticial chunk type "eXIf". > sessionInfo() R version 4.0.0 (2020-04-24) Platform:
2011 Jan 27
2
help for a loop procedure
Hello everybody! I’m trying to define the optimal number of surveys to detect the highest number of species within a monitoring season/session. To do this I want to run all the possible combinations between a set of samples and to calculate the total number of species for each combination of 2, 3, 4 …n samples events, so that at the end I will be able to define which is the lowest number of
2018 Mar 12
0
subsetting comparison problem
> On Mar 11, 2018, at 3:32 PM, Neha Aggarwal <aggarwalneha2000 at gmail.com> wrote: > > Hello All, > I am facing a unique problem and am unable to find any help in R help pages > or online. I will appreciate your help for the following problem: > I have 2 data-frames, samples below and there is an expected output > > R Dataframe1: > C1 C2
2011 Sep 03
3
question with uniroot function
Dear all, I have the following problem with the uniroot function. I want to find roots for the fucntion "Fp2" which is defined as below. Fz <- function(z){0.8*pnorm(z)+p1*pnorm(z-u1)+(0.2-p1)*pnorm(z-u2)} Fp <- function(t){(1-Fz(abs(qnorm(1-(t/2)))))+(Fz(-abs(qnorm(1-(t/2)))))} Fp2 <- function(t) {Fp(t)-0.8*t/alpha} th <- uniroot(Fp2, lower =0, upper =1,