|
[Date Index]
[Thread Index]
[Author Index]
Re: Controlling Print[].
- To: mathgroup at smc.vnet.net
- Subject: [mg54031] Re: Controlling Print[].
- From: Josef Karthauser <joe at tao.org.uk>
- Date: Tue, 8 Feb 2005 05:31:08 -0500 (EST)
- References: <016601c50d2d$621993e0$6400a8c0@Main>
- Sender: owner-wri-mathgroup at wolfram.com
That looks like a really good solution. Thanks for that.
Joe
On Mon, Feb 07, 2005 at 10:54:59AM -0500, Carl K. Woll wrote:
> Josef,
>
> I like Theodore Gray's solution:
>
> Showstatus[status_] :=
> LinkWrite[$ParentLink,
> SetNotebookStatusLine[FrontEnd`EvaluationNotebook[],
> ToString[status]]]
>
> Just use ShowStatus instead of Print, and whatever you print will show up in
> the status line. Note that the status line is present in the default style
> sheet. If you happen to use a style sheet which doesn't have a status line,
> you can fix this by going to the option inspector, and setting the
> WindowElements option to include "StatusArea".
>
> Carl Woll
>
>
> "Josef Karthauser" <joe at tao.org.uk> wrote in message
> news:cu78se$m8e$1 at smc.vnet.net...
> >
> > Dear anyone know a way of controlling Print[]? I've got a large loop
> > that I want to keep tabs on, and see how quickly it is running. Within
> > one of the inner loops I'm doing something like 'a // Print' where 'a'
> > is some kind of location indicator. This is fine in principle, but in
> > practice the inner loop runs lots of times and so I get a single output
> > box per time (several pages). What I would like to do is have them
> > printed one after another on the same line, i.e
> >
> > for(i = 0; i < 1000; i++) {
> > printf("%d ", i);
> > }
> >
> > instead of
> >
> > for(i = 0; i < 1000; i++) {
> > printf("%d\n ", i);
> > }
> >
> > Is this kind of thing possible? I can imagine constructing a string in
> > the loop and then printing that, but that wouldn't give the desired
> > affect because it would effectively behave like buffered output; what I
> > want is unbuffered, i.e. print the variable to the current output box,
> > but don't finish it yet as the next output also want to go here.
> >
> > Joe
> > --
>
>
>
>
>
--
Josef Karthauser (joe at tao.org.uk) http://www.josef-k.net/
FreeBSD (cvs meister, admin and hacker) http://www.uk.FreeBSD.org/
Physics Particle Theory (student) http://www.pact.cpes.sussex.ac.uk/
================ An eclectic mix of fact and theory. =================
Prev by Date:
Re: Controlling Print[].
Next by Date:
Re: NDSolve and differential equation system
Previous by thread:
Re: Controlling Print[].
Next by thread:
Re: Controlling Print[].
|