Displaying 20 results from an estimated 35 matches for "autoprint".
Did you mean:
autopoint
2019 May 21
3
print.<strorageMode>() not called when autoprinting
Letting a user supply the autoprint function would be nice also. In a way
you can already do that, using addTaskCallback(), but that doesn't let you
suppress the standard autoprinting.
Having the default autoprinting do its own style of method dispatch doesn't
seem right.
Bill Dunlap
TIBCO Software
wdunlap tibco.com
On T...
2019 May 16
3
print.<strorageMode>() not called when autoprinting
In R-3.6.0 autoprinting was changed so that print methods for the storage
modes are not called when there is no explicit class attribute. E.g.,
% R-3.6.0 --vanilla --quiet
> print.function <- function(x, ...) { cat("Function with argument list ");
cat(sep="\n ", head(deparse(args(x)), -1...
2019 May 21
2
print.<strorageMode>() not called when autoprinting
...;
Bill Dunlap
TIBCO Software
wdunlap tibco.com
On Tue, May 21, 2019 at 9:31 AM Martin Maechler <maechler at stat.math.ethz.ch>
wrote:
> >>>>> William Dunlap via R-devel
> >>>>> on Thu, 16 May 2019 11:56:45 -0700 writes:
>
> > In R-3.6.0 autoprinting was changed so that print methods for the
> storage
> > modes are not called when there is no explicit class attribute.
> E.g.,
>
> > % R-3.6.0 --vanilla --quiet
> >> print.function <- function(x, ...) { cat("Function with argument
> list &qu...
2019 May 22
0
print.<strorageMode>() not called when autoprinting
>>>>> William Dunlap
>>>>> on Tue, 21 May 2019 12:11:45 -0700 writes:
> Letting a user supply the autoprint function would be nice also. In a way
> you can already do that, using addTaskCallback(), but that doesn't let you
> suppress the standard autoprinting.
> Having the default autoprinting do its own style of method dispatch doesn't
> seem right.
I agree (if I u...
2019 May 22
1
print.<strorageMode>() not called when autoprinting
...:50, Martin Maechler <maechler at stat.math.ethz.ch> wrote:
>
> I'm pretty sure that all teaching and documentation about S and R
> has suggested that print(f) and auto-printing should result in
> the same output _ AFAIR also for S4 objects
I agree with the principle that autoprint and print() should be
equivalent for users. However it also seems that print calls in
packages should be independent of user customisations. For instance a
package author might gather tabular data in a matrix or data frame and
print() it as part of a larger print method. In that case, user
customis...
2019 May 21
0
print.<strorageMode>() not called when autoprinting
...to customise auto-printing for base types
and even classed objects as that'd be useful for both users and IDEs.
However S3 dispatch may not be optimal for this because it essentially
requires polluting the global environment with print methods. Maybe
it'd make sense to add getOption("autoprint") which should be set to
a user- or environment- supplied function. That function would do the
dispatch. I'd be happy to send a patch for this, if it makes sense.
Best,
Lionel
> On 21 May 2019, at 13:38, William Dunlap via R-devel <r-devel at r-project.org> wrote:
>
> It...
2017 Jan 09
1
problem with print.generic(x)deparse(substitute(x))
...> print.dum <- function(x, ...)
>> deparse(substitute(x))
>>
>> print(k) # Prints "k" as expected
>> #####**** THE FOLLOWING PRINTS NOTHING:
>> k # Why?
>
> Because it doesn't work that way...
>
> First of all, your print.dum relies on autoprinting of its return value, it doesn't print anything itself. That's not how one usually writes print methods: You should print something and (usually) return the argument invisibly.
>
> Autoprinting calls the print method to do the actual printing and returns the object invisibly, irresp...
2017 Jan 09
2
problem with print.generic(x)deparse(substitute(x))
Hi, All:
I'm having trouble getting deparse(substitute(x)) inside
print.generic to consistently
I'm having trouble getting a print.something to work
consistently. Consider the following toy example:
# Define an object of class 'dum'
k <- 1
class(k) <- 'dum'
str(k) # as expected
# Define print.dum
print.dum <- function(x, ...)
2017 Jan 09
0
problem with print.generic(x)deparse(substitute(x))
...pected
>
> # Define print.dum
> print.dum <- function(x, ...)
> deparse(substitute(x))
>
> print(k) # Prints "k" as expected
> #####**** THE FOLLOWING PRINTS NOTHING:
> k # Why?
Because it doesn't work that way...
First of all, your print.dum relies on autoprinting of its return value, it doesn't print anything itself. That's not how one usually writes print methods: You should print something and (usually) return the argument invisibly.
Autoprinting calls the print method to do the actual printing and returns the object invisibly, irrespective o...
2003 Sep 16
3
Question in Using sink function
Could anyone please explain to me why the following writes nothing into
"all.Rout"
file? If the "for" loop is removed, t.test output can be written into
"all.out".
Thanks in advance.
Minghua Yao
......
zz <- file("all.Rout", open="wt")
sink(zz)
for(i in 1:n)
{
Cy3<-X[,2*i-1];
Cy5<-X[,2*i];
t.test(Cy3, Cy5)
2012 Nov 06
2
Question on callNextMethod
I don't understand why I get the following results. I define two classes
'Base' and 'Derived', the latter of which 'contains' the first. I then
define a generic method 'test' and overload it for each of these classes. I
call 'callNextMethod()' in the overload for Derived. From the output, it
appears that the overload for Base gets called twice. Why is
2016 Sep 02
4
withAutoprint({ .... }) ?
...; FAQ Q7.22).
> So you need:
> print(t(tradeStats('macross')))
> if you want the output printed to the console.
indeed, and "of course"" ;-)
As my subject indicates, this is another case, where it would be
very convenient to have a function
withAutoprint()
so the OP could have (hopefully) have used
withAutoprint(source(..))
though that would have been equivalent to the already nicely existing
source(.., print.eval = TRUE)
which works via the withVisible(.) utility that returns for each
'expression' if it would auto print or not, a...
2016 Sep 02
1
withAutoprint({ .... }) ?
...oss')))
>>
>> > if you want the output printed to the console.
>>
>> indeed, and "of course"" ;-)
>>
>> As my subject indicates, this is another case, where it would be
>> very convenient to have a function
>>
>> withAutoprint()
>>
>> so the OP could have (hopefully) have used
>> withAutoprint(source(..))
>> though that would have been equivalent to the already nicely existing
>>
>> source(.., print.eval = TRUE)
>>
>> which works via the withVisible(.) utility that r...
2001 Jan 09
0
printing configuration issues...
first:
Can I do the autoprinter drivers for 2000 on Samba 2.0.6?
Second:
Is printer config data available from the server and if so how? With
our old 2000 server which crashed every few weeks the config
data was stored on the server (such as "does the printer have the duplex
tray installed?") now eac...
1999 May 03
1
bug
-------------------------------------------------
SAMPLE SCRIPT:
x<-rnorm(50)
y<-12*x+30*rnorm(10)
ff<-lm(y~x)
sink("output.txt")
print(ff) # this work give basic coefficients
summary(ff) # should give Rsquare etc
sink()
-------------------------------------------------
Having fitted a curve on a data set, I am trying
to write all the statistics about the fit to a
file.
In
2016 Sep 24
2
withAutoprint({ .... }) ?
>>>>> William Dunlap <wdunlap at tibco.com>
>>>>> on Fri, 2 Sep 2016 08:33:47 -0700 writes:
> Re withAutoprint(), Splus's source() function could take a expression
> (literal or not) in place of a file name or text so it could support
> withAutoprint-like functionality in its GUI. E.g.,
>> source(auto.print=TRUE, exprs.literal= { x <- 3:7 ; sum(x) ; y <- log(x)
> ;...
2006 Oct 15
1
Mute script
Hi,
I tried to run the following script with R 2.4.0. The data stuff is commented
out because data are already in memory.
#db <- read.csv("normais.csv", sep=";", quote="", header=T)
sink("normais-chi.txt", append=T, type = "output", split=T)
#sink("normais-chi.txt", append=T)
table(db$agua, db$mBerg)
chisq.test(db$agua, db$mBerg,
2007 Dec 31
1
Program output to file using a batch command file
If I copy the following commands in my batch file to the R console, R
creates a file named "basicStatsIBM.lis" with the program output in it:
Sortie <- file(description = "basicStatsIBM.lis", open = "wt", blocking =
TRUE,
encoding = "UTF-8")
sink(file = Sortie, append = FALSE, type = "output", split = FALSE)
basicStats(ibm)
close(Sortie)
2006 May 17
2
No output in sourced R program
Hi,
If I type it in the command line I get, as expected:
> 1:30
[1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
23 24 25
[26] 26 27 28 29 30
> q()
Save workspace image? [y/n/c]: n
If I create a program 02e451444d6a46acf551996579092c911b90aa8e.R and run
it I get
R : Copyright 2006, The R Foundation for Statistical Computing
Version 2.3.0 (2006-04-24)
>
2016 Sep 02
0
withAutoprint({ .... }) ?
...> print(t(tradeStats('macross')))
>
> > if you want the output printed to the console.
>
> indeed, and "of course"" ;-)
>
> As my subject indicates, this is another case, where it would be
> very convenient to have a function
>
> withAutoprint()
>
> so the OP could have (hopefully) have used
> withAutoprint(source(..))
> though that would have been equivalent to the already nicely existing
>
> source(.., print.eval = TRUE)
>
> which works via the withVisible(.) utility that returns for each
> 'expres...