Displaying 20 results from an estimated 1100 matches similar to: "Categorizing Fonts using Statistical Methods"
2024 Sep 05
3
BUG: atan(1i) / 5 = NaN+Infi ?
On 2024-09-05 4:23 p.m., Leo Mada via R-help wrote:
> Dear R Users,
>
> Is this desired behaviour?
> I presume it's a bug.
>
> atan(1i)
> # 0+Infi
>
> tan(atan(1i))
> # 0+1i
>
> atan(1i) / 5
> # NaN+Infi
There's no need to involve atan() and tan() in this:
> (0+Inf*1i)/5
[1] NaN+Infi
Why do you think this is a bug?
Duncan Murdoch
2024 Sep 05
2
BUG: atan(1i) / 5 = NaN+Infi ?
atan(1i) -> 0 + Inf i
complex(1/5) -> 0.2 + 0i
atan(1i) -> (0 + Inf i) * (0.2 + 0i)
-> 0*0.2 + 0*0i + Inf i * 0.2 + Inf i * 0i
infinity times zero is undefined
-> 0 + 0i + Inf i + NaN * i^2
-> 0 + 0i + Inf i - NaN
-> NaN + Inf i
I am not sure how complex arithmetic could arrive at another answer.
I advise against messing with infinities... use atan2() if you don't
2024 Sep 05
1
BUG: atan(1i) / 5 = NaN+Infi ?
Dear Bert,
These behave like real divisions/multiplications:
complex(re=Inf, im = Inf) * 5
# Inf+Infi
complex(re=-Inf, im = Inf) * 5
# -Inf+Infi
The real division / multiplication should be faster and also is well behaved. I was expecting R to do the real division/multiplication on a complex number. Which R actually does for these very particular cases; but not when only Im(x) is Inf.
2024 Sep 05
1
BUG: atan(1i) / 5 = NaN+Infi ?
> complex(real = 0, imaginary = Inf)
[1] 0+Infi
> Inf*1i
[1] NaN+Infi
>> complex(real = 0, imaginary = Inf)/5
[1] NaN+Infi
See the Note in ?complex for the explanation, I think. Duncan can correct
if I'm wrong.
-- Bert
On Thu, Sep 5, 2024 at 3:20?PM Leo Mada <leo.mada at syonic.eu> wrote:
> Dear Bert,
>
> These behave like real divisions/multiplications:
>
2024 Jun 02
1
Tools to modify highlighted areas in pdf documents?
? Sat, 1 Jun 2024 16:16:23 +0000
Leo Mada via R-help <r-help at r-project.org> ?????:
> When highlighting pdf-documents with Microsoft Edge, the bounding box
> is sometimes misplaced, and quite ugly so. It also lacks the ability
> to draw lines or arrows.
>
> On the other hand, I did not get used to Acrobat Reader: it usually
> involves much more effort to add specific
2023 Oct 16
1
Create new data frame with conditional sums
If one makes the reasonable assumption that Pct is much larger than
Cutoff, sorting Cutoff is the expensive part e.g O(nlog2(n) for
Quicksort (n = length Cutoff). I believe looping is O(n^2). Jeff's
approach using findInterval may be faster. Of course implementation
details matter.
-- Bert
On Mon, Oct 16, 2023 at 4:41?AM Leonard Mada <leo.mada at syonic.eu> wrote:
>
> Dear
2024 Sep 05
2
BUG: atan(1i) / 5 = NaN+Infi ?
Perhaps
> Inf*1i
[1] NaN+Infi
clarifies why it is *not* a bug.
(Boy, did that jog some long dusty math memories :-) )
-- Bert
On Thu, Sep 5, 2024 at 2:48?PM Duncan Murdoch <murdoch.duncan at gmail.com>
wrote:
> On 2024-09-05 4:23 p.m., Leo Mada via R-help wrote:
> > Dear R Users,
> >
> > Is this desired behaviour?
> > I presume it's a bug.
> >
2023 Oct 16
1
Create new data frame with conditional sums
Dear Jason,
The code could look something like:
dummyData = data.frame(Tract=seq(1, 10, by=1),
?? ?Pct = c(0.05,0.03,0.01,0.12,0.21,0.04,0.07,0.09,0.06,0.03),
?? ?Totpop = c(4000,3500,4500,4100,3900,4250,5100,4700,4950,4800))
# Define the cutoffs
# - allow for duplicate entries;
by = 0.03; # by = 0.01;
cutoffs <- seq(0, 0.20, by = by)
# Create a new column with cutoffs
dummyData$Cutoff
2024 Jun 02
2
R code for overlapping variables -- count
Dear Shadee,
If you have a data.frame with the following columns:
n = 100; # population size
x = data.frame(
??????Sex = sample(c("M","F"), n, T),
??????Country = sample(c("AA", "BB", "US"), n, T),
??????Income = as.factor(sample(1:3, n, T))
)
# Dummy variable
ONE = rep(1, nrow(x))
r = aggregate(ONE ~ Sex + Income + Country, length, data = x)
2023 Oct 21
1
Issue from R-devel: subset on table
My mistake!
It does actually something else, which is incorrect. One could still use
(although the code is more difficult to read):
subset(tmp <- table(sample(1:10, 100, T)), tmp > 10)
Sincerely,
Leonard
On 10/21/2023 10:26 PM, Leonard Mada wrote:
> Dear List Members,
>
> There was recently an issue on R-devel (which I noticed only very late):
>
2024 Jan 30
2
Use of geometric mean for geochemical concentrations
Dear Rich,
It depends how the data is generated.
Although I am not an expert in ecology, I can explain it based on a biomedical example.
Certain variables are generated geometrically (exponentially), e.g. MIC or Titer.
MIC = Minimum Inhibitory Concentration for bacterial resistance
Titer = dilution which still has an effect, e.g. serially diluting blood samples;
Obviously, diluting the
2023 Jan 12
1
return value of {....}
Dear Akshay,
The best response was given by Andrew. "{...}" is not a closure.
This is unusual for someone used to C-type languages. But I will try to
explain some of the rationale.
In the case that "{...}" was a closure, then external variables would
need to be explicitly declared before the closure (in order to reuse
those values):
intermediate = c()
{
??? intermediate
2024 Sep 05
2
BUG: atan(1i) / 5 = NaN+Infi ?
Dear R Users,
Is this desired behaviour?
I presume it's a bug.
atan(1i)
# 0+Infi
tan(atan(1i))
# 0+1i
atan(1i) / 5
# NaN+Infi
There were some changes in handling of complex numbers. But it looks like a bug.
Sincerely,
Leonard
[[alternative HTML version deleted]]
2007 Mar 27
3
Bridging R to OpenOffice
Dear members of the R Development Team,
I am looking for people with a deep understanding of R internals to
assist in bridging R to OpenOffice.
While R is a state of the art statistical environment, less experienced
users often find it difficult to work with R. Therefore, I believe that
a bridge between R and a spreadsheet program will make this transition
less painful. I sincerely believe
2010 Jun 28
10
Long delays when launching programs for the first time in my Windows 7 Profile (Samba 3.4.3 as PDC)
Hello dear Samba users!
My setup:
=================
Server:
- openSUSE 11.2 - 64 bit
- Samba 3.4.3 running as PDC. Roaming profiles active
- DNS Server (bind 9)
- DHCP-Server, which dynamically updates the zone files of the DNS
Client:
- Windows 7 Professional - 64 bit, english
My problems:
=================
1.
The first time when I login a new user on the client, it takes
2009 Aug 11
1
Categorizing Lines
Hi all, i have a dataset of 3D coordinates and can't figure out how
to' tell R which One Are the individuals:
I have 3 columns which i named x,y and z
And then i have 2607 Lines, but each specimen is 33 Lines (79 specimens)
How can i tell R to' categorize individuals every 33 Lines?
Thanks in advance
2010 Sep 14
2
[LLVMdev] Thumb categorizing TST wrongly
I see strangeness on Thumb TST (tTST) predicate 'isCompare'
It is true for regular ARM, false for Thumb:
(gdb) p MI->dump()
TSTri %reg16397, 3, pred:14, pred:%reg0, %CPSR<imp-def>; GPR:%
reg16397
$24 = void
(gdb) p MI->getDesc().isCompare()
$25 = true
(gdb) p MI->dump()
tTST %reg16396, %reg16397, pred:14, pred:%reg0, %CPSR<imp-def>;
tGPR:%reg16396,16397
2010 Sep 14
0
[LLVMdev] Thumb categorizing TST wrongly
On Sep 14, 2010, at 12:09 PM, Gabor Greif wrote:
> I see strangeness on Thumb TST (tTST) predicate 'isCompare'
>
> It is true for regular ARM, false for Thumb:
>
> (gdb) p MI->dump()
> TSTri %reg16397, 3, pred:14, pred:%reg0, %CPSR<imp-def>; GPR:%
> reg16397
> $24 = void
> (gdb) p MI->getDesc().isCompare()
> $25 = true
>
>
> (gdb)
2008 Jan 07
1
help on log-gamma regresion model with R
Hii all, may I introduce myself. my name is Putro Nugroho i'am astudent of Gadjah Mada University, i'am doing on my final exam about Parametric Regression Model with gamma and log-gamma regression model. I have a problem about the syntax program on R because it doesn't work with gamma distribution with log link function. when I use zelig package it doesn't work when the data is
2024 Jun 01
2
Tools to modify highlighted areas in pdf documents?
Dear R-Users,
Are there any packages that enable the modifications of highlighted areas / annotations in pdf documents?
It seems feasible - I have explored some R code (see below). However, I would rather avoid to reinvent the wheel.
The problem:
When highlighting pdf-documents with Microsoft Edge, the bounding box is sometimes misplaced, and quite ugly so. It also lacks the ability to draw