Displaying 17 results from an estimated 17 matches for "hundredth".
2011 Dec 19
1
Speed issue when writing to RGui console from tcl/tk GUI
...tcl/tk GUI.
Here are functions to write a lot of output, and to display how long it
takes.
printsalot <- function(n)
{
for(i in 1:n) cat(i, fill = TRUE)
}
timings <- function(n = 1e3)
{
print(system.time(printsalot(n)))
}
Calling timings() from the console reveals a run time of a few hundredths
of a second.
The following GUI has two buttons. Clicking the "slow" buttons just calls
timings directly, and takes several seconds to run. However, if we request
input from the console, via readline (the "fast" button) then the timing
drops back down to hundredths of a secon...
2005 Apr 01
1
Vernier Caliper function vernier()
...I have therefore implemented, and hereby donate to the
R community, a new function vernier() which implements
the Venier Caliper.
Its definition is below. Test it by entering
vernier(pi+sqrt(.182))
By following the instructions you should find that
the result is
x = 3 Units + 5 Tenths + 7 Hundredths
which is good enough for anyone. It generalises to
non-decimal Vernier Calipers (change the default "n=10",
but I leave it to you to work out how to deal with the
texts).
All best wishes,
Ted.
vernier <- function(x,n=10) {
dS<-1/n; dV<-((n-1)/n)*dS
U<-floor(x)
plot(c...
2010 Mar 26
2
Odd results with %% and conserving memory
...have a matrix with double components. It's taking up a lot of memory, so I
want to multiply then turn it to integers. I'm pretty certain that there are
only 2 decimal places, but I wanted to check by using modulo. E.g.
mat = matrix(11:50/100, ncol=4,nrow=10) #Matrix with values out to the
hundredths
any((mat * 100)%%1!=0)
But oddly enough it doesn't work. Even in this simple example the result I
get is this:
[,1] [,2] [,3] [,4]
[1,] 0.000000e+00 0.000000e+00 0 0
[2,] 0.000000e+00 0.000000e+00 0 0
[3,] 0.000000e+00 0.000000e+00 0 0
[4,] 1.776357...
2004 Nov 16
0
metadata switches for ffmpeg2theora
...gt;audioflag=1;
/*
- if (ogg_stream_eos (&info.vo)){
- info.audioflag = 0;
+ if (ogg_stream_eos (&info->vo)){
+ info->audioflag = 0;
return 0;
}
*/
return 0;
}
-void print_stats(double timebase){
+static void print_stats(theoraframes_info *info, double timebase){
int hundredths = timebase * 100 - (long) timebase * 100;
int seconds = (long) timebase % 60;
int minutes = ((long) timebase / 60) % 60;
int hours = (long) timebase / 3600;
- if(info.vkbps<0)
- info.vkbps=0;
- if(info.akbps<0)
- info.akbps=0;
+ if(info->vkbps<0)
+ info->vkbps=0;
+ if(inf...
2008 Jul 24
1
Excerpting a summary from my marked-up blog post without breaking html tags?
Hi there,
I''m working on a simple blog project. I''d like to automatically
generate a 100 word excerpt of each article to display on the main
page, and require the user to click on the article to read the whole
thing. The problem is, if the hundredth word is in the middle of a
block quote or a heading or something, the whole page gets messed up.
What''s the easiest way to close any tags that might still be open at
the end of the excerpt?
For what it''s worth, posts are marked up using textile and
superredcloth.
Thanks for your...
2006 Aug 30
1
Can ONLY log in as root-console perms problem
...t; 0660 root.disk
<console> 0600 <pilot> 0660 root.uucp
<console> 0600 <jaz> 0660 root.disk
I cannot log in on a text console either, only root can. When I try it instantly
returns to the login prompt. Sometimes I'll see a short message flash for a
hundredth of a second that looks like it might be the same one approximated
above.
I saw a series of messages from someone else saying he had to back out to the
previous kernel, apparently because of a NVIDIA driver issue, so I tried that
and it made no difference. He also suggested adding "pci=noacpi...
2005 Oct 05
1
Simple encodig sample...
...ge_granulepos(
&videopage ) );
/* flush a video page */
video_bytesout += fwrite( videopage.header, 1,
videopage.header_len, outfile );
video_bytesout += fwrite( videopage.body, 1, videopage.body_len,
outfile );
timebase = videotime;
{
int hundredths = timebase * 100 - (long) timebase * 100;
int seconds = ( long) timebase % 60;
int minutes = ( (long) timebase / 60 ) % 60;
int hours = (long) timebase / 3600;
vkbps = rint( video_bytesout * 8. / timebase * .001 );
fprintf( stderr, "...
2010 Aug 24
1
Time and space considerations in using predict.glm.
....121
This may be an issue of swap-time, and so it could potentially be solved by
addressing my first question above. However, given that I am essentially
asking R to compute
1 / (1 + exp(-(b0 + b1*x1 + b2*x2 + b3*x1*x2)))
I can't see any reason why this request should be taking longer than a
hundredth or a thousandth of a second, say. Obviously R is providing a much
greater level of functionality than I am requiring in this particular
instance, so my overall question is what is the best way for me to reduce
the size of the data I have to store in my GLM models, and to increase the
speed at which...
2007 Nov 21
6
mod_proxy_balancer under heavy load.
...rence to stability here.
in puppetmasterd at line 261, I''ve modified the Mongrel instantiation from:
server = Mongrel::HttpServer.new(addr, Puppet[:masterport])
to
webserver = Mongrel::HttpServer.new(addr, Puppet[:masterport], timeout=4)
timeout is a throttling parameter for Mongrel in hundredths of a second
between socket.accept() calls.
I''m planning to submit some patches that let you configure more mongrel
parameters as puppetmasterd config settings.
My apache virtual host config looks like this. Note some odd differences
here with the RequestHeaders, as I''ve got a s...
2010 Oct 12
0
Stripes in the plot
..."/Users/R/Code/data/KS_River_Basin_Dissolve.shp")
states <- readShapeLines("/Users/R/Code/data/statesp020.shp")
ppt <- read.table ('/Users/R/Code/LULC/pptnewlulc.dat', header = FALSE) # the size is 5764(pixels) x 528(periods)
ppt <- (ppt/100)*25.4 #convert from hundredths of an inch to mm
# the range of the area
plat <- as.matrix(seq(38.16836,41.29575,by=0.07273)) #dimension is (44,1)
plon <- as.matrix(seq(-103.9752,-94.5,by=0.07273)) #dimension is (131,1)
ppt1 <- ppt[,1] #length is 5764
ppt1 <- matrix(as.numeric(ppt[,1]), nrow=131, ncol=44)
> pp...
2010 Aug 24
0
Time and space considerations in using predict.glm()
....121
This may be an issue of swap-time, and so it could potentially be solved by
addressing my first question above. However, given that I am essentially
asking R to compute
1 / (1 + exp(-(b0 + b1*x1 + b2*x2 + b3*x1*x2)))
I can't see any reason why this request should be taking longer than a
hundredth or a thousandth of a second, say. Obviously R is providing a much
greater level of functionality than I am requiring in this particular
instance, so my overall question is what is the best way for me to reduce
the size of the data I have to store in my GLM models, and to increase the
speed at which...
2002 Aug 23
2
why delete.response?
Hi all,
I am running R1.5.0 under unix.
I recently used the function 'predict.tree' to make predictions with a
tree object and a dataframe of numeric items. The predict.tree internally,
calls a function 'delete.response'.
When I removed this function call from the source code of predict.tree, it
ran 10 times faster without any differences in the result obtained.
The
2011 May 05
5
May 05 07:20:21 imap: Warning: Time jumped forwards 16 seconds
Hello
I get this warning in dovecot.log
the machine is running ntpd so this is
a bit strange ...
2015 Jan 23
3
Orwell's 1984 from Freedesktop,org?
...>
> They tried to do that in RH as well, but a bug report was filed, and it
> was
> changed.
>
> In my less than humble opinion, this is how it should be. A
> non-privileged
> user should not be allowed to make changes to the system.
>
I would second that (or third, or hundredth...). I hate Adobe for putting
SUID-ed "plugin-config", thus enabling regular user write where only root
can. This crap triggers my system integrity alarms. I always have to
remove SUID bit then set immutable bit so the crap doesn't resurrect with
their update. In the same list of bad...
2017 Dec 05
9
Who wants faster LLVM/Clang builds?
Hi,
Recently I've done some experiments on the LLVM/Clang code and discovered that many of our source files often include unnecessary header files. I wrote a simple tool that eliminates redundant includes and estimates benefits of doing it, and the results were quite nice: for some files we were able to save 90% of compile time! I think we want to apply some of the cleanups I found, but
2015 Jan 23
5
Orwell's 1984 from Freedesktop,org?
On Thu, January 22, 2015 9:05 pm, Always Learning wrote:
>
> On Thu, 2015-01-22 at 21:19 -0500, Bill Maltby (C4B) wrote:
>
>> I object to this sort of crap. Hidden, no reason for an *IX desktop to
>> be forced to ignore or deal with this crap.
>>
>> Anybody else seeing it?
>>
>> In case attachments aren't allowed in the list, here's the Dropbox
2009 Feb 26
42
Need to test serial port connection
I recently bought a new UPS, and I''m attempting to use nut to monitor it.
Following setup instructions everything seemed to go well until it came to
testing the connection, which failed.
There is just one serial connector on the computer, so I set it to
monitor /dev/ttyS0. Either that is wrong, or communication is failing.
I''ve been told to try minicom to monitor it,