yes, thank you for catching that slip.
On Tue, Jun 5, 2018 at 11:29 PM, Christopher W. Ryan
wrote:
> Richard--
>
> Nice. If I understand your code correctly, in the line
>
> ddm <- matrix("", (n+2) %/% nc, nc)
>
> I could instead use
>
> ddm <- matrix("", (n + nc - 1) %/% nc, nc)
>
> for generali
Richard--
Nice. If I understand your code correctly, in the line
ddm <- matrix("", (n+2) %/% nc, nc)
I could instead use
ddm <- matrix("", (n + nc - 1) %/% nc, nc)
for generalizability, as I may have to increase nc as the list of words
grows ever longer.
Thanks everyone. Several good suggesti
I think this is cuter, and it is a hair faster.
n <- length(dd)
ddm <- matrix("", (n+2) %/% nc, nc)
ddm[1:n] <- dd
Rich
> system.time(for (i in 1:1) {
+ add <- nc - (length(dd) %% nc)
+ dd2 <- c(dd, rep("", add))
+ ddm <- matrix(dd2, ncol = nc)
+ })
user system elapsed
0.064 0.100
> On Jun 5, 2018, at 9:45 AM, Christopher W Ryan wrote:
>
> I'm writing code for a recurring report, using an R --> Sweave --> pdflatex
> workflow. It includes a character vector of short words that I would like
> to display compactly, in columns on a page, rather than one word per line,
> whi
On 05/06/2018 7:49 PM, zListserv wrote:
p.s. It seems to work for print command, but not for head, tail, or printing a
data frame, per below. Any way fix the others so they all left-justify?
You haven't shown us what you did.
Duncan Murdoch
__
R-
p.s. It seems to work for print command, but not for head, tail, or printing a
data frame, per below. Any way fix the others so they all left-justify?
R> x <- as.data.frame(rep(c("a", "ab", "abc"), 7))
R> print(x)
rep(c("a", "ab", "abc"), 7)
a
ab
Duncan et al
I tried to redefine print.data.frame the way you suggested, but I misplaced the
ellipsis by putting it at the end of the function definition instead of
immediately following the name of the data frame.
Works now.
Thanks!
> On 2018-06-05, at 12:39, Duncan Murdoch wrote:
>
> On
I think the OP does not realize that head() and tail() do not print anything.
They extract the first or last values/rows and if they are not assigned to an
object, they automatically go to print().
Redefining print.data.frame would also fix that problem.
David L. Carlson
Department of Anthropo
I'm writing code for a recurring report, using an R --> Sweave --> pdflatex
workflow. It includes a character vector of short words that I would like
to display compactly, in columns on a page, rather than one word per line,
which would waste a lot of space. The vector of words will increase
unpred
On 05/06/2018 10:24 AM, zListserv wrote:
Many (most?) R functions print character strings and factor labels
right-justified.
Could you be more specific? I see character strings left justified,
e.g. x <- rep(c("a", "ab", "abc"), 7) prints as
[1] "a" "ab" "abc" "a" "ab" "abc" "a"
[
Hello,
I had a similar problem a while ago.And it was also a problem with
AVG.Apparently these false positives are a known issue with that AV. At the
time I got an answer directing me to an online source on this but it was some
3-4 years ago and I don't believe I still have it.
Anyway, the probl
Dear
I trying to convert data frame in xml using R in Spotfire. But getting
error:
"In xmlRoot.XMLInternalDocument(currentNodes[[1]]) : empty XML document"
Please Help.
Regards
Devendra
Regards
Devendra
Mobile-+91 8884266448
[[alternative HTML version deleted]]
_
Many (most?) R functions print character strings and factor labels
right-justified.
print accepts right=FALSE to print character strings left-justified, but
neither head nor tail seem to do so, and even print is a little inconsistent
depending on whether it's done while knitting.
Is there a wa
These are almost always false positives. The checks are based on checksumming
and sometimes a perfectly innocent .exe will match the checksum of some
virus/malware. The .exe is rebuilt nightly and changes slightly between builds,
so you may want just retry after a day or so.
(The AV vendors are
14 matches
Mail list logo