Displaying 20 results from an estimated 5000 matches similar to: "Histogram not plotting correct breaks"
2010 Oct 08
4
function using values separated by a comma
Hello,
I have a dataframe (tab separated file) which looks like the example below -
two values separated by a comma, and tab separation between each of these.
[,1] [,2] [,3] [ ,4]
[1,] 0,1 1,3 40,10 0,0
[2,] 20,5 4,2 10,40 10,0
[3,] 0,11 1,2 120,10 0,0
I would like to calculate the percentage of the smallest number separated by
the comma by:
1) summing the values e.g. for
2010 May 02
2
Replace query
Hi,
I'm trying to replace all values equal to 1 in one file (a) with the value
in the corresponding column in a separate file (b). Example below.
Any help (and brief notes if poss) much appreciated. Thanks!!
file a:
0,0,1,1,0
1,0,0,0,1
0,0,0,0,0
1,0,1,1,0
file b:
3,4,6,8,11
output request:
0,0,6,8,0
3,0,0,0,11
0,0,0,0,0
3,0,6,8,0
--
View this message in context:
2010 Apr 09
3
How to replace all non-maximum values in a row with 0
Hi,
I would like to replace all the max values per row with "1" and all other
values with "0". If there are two max values, then "0" for both. Example:
from:
2 3 0 0 200
30 0 0 2 50
0 0 3 0 0
0 0 8 8 0
to:
0 0 0 0 1
0 0 0 0 1
0 0 1 0 0
0 0 0 0 0
Thanks!
--
View this message in context:
2010 Oct 12
1
Comparison of two files with multiple arguments
Hello,
I have an example file which can be generated using:
dat <- read.table(tc <- textConnection(
'T T,G G T
C NA G G
A,T A A NA'), sep="")
I also have a reference file with the same number of rows, for example:
G
C
A
I would like to transform the file to numerical values using the following
arguments:
1) Where data points have two letters separated by a comma, e.g.
2010 Apr 30
1
How to generate a distance matrix?
Hi,
I'm trying to generate a distance matrix between sample pairs (example
below). I'm not very familiar with the loop command which I expect I will
need for this. The example below demosntrates what I'd like to get out of
the data - essentially, to calculate the proportion of positions where two
samples differ.
Any help much appreciated! Also, any notes on how the functions work
2005 Aug 30
1
loglinear model selection
Hi R-masters!
I have a problem and need your help.
I have 9 discrete variables with 2 levels each.
In exploratory analisys I generate one matrix with chi-square for tables
with 2 ariables each with this script
setwd("F:/")
dados<-read.csv("log.csv")[,2:10]
dados.x<-matrix(NA,ncol=9,nrow=9)
for(i in 1:8){
for(j in (i+1):9){
tab<-table(dados[,i],dados[,j])
2004 Jul 13
1
MLE, precision
Hi, everyone
I am trying to estimate 3 parameters for my survival
function. It's very complicated. The negative
loglikelihood function is:
l<- function(m1,m2,b) -sum( d*( log(m1) + log(m2)
+ log(1- exp(-(b + m2)*t)) ) + (m1/b - d)*log(m2 +
b*exp(-(b + m2)*t) ) + m1*t - m1/b*log(b+m2) )
here d and t are given, "sum" means sum over these
two vairables.
the parameters
2011 May 23
3
How can I use option --bare in Rails 3.1 for CoffeeScript?
Someone know how can I use this option in Rails 3.1?
Now CoffeScript puts a function ".call(this)" on each file, but I want
to remove this.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this
2002 Dec 13
1
histogram bug?: type='count', unequal breaks
I ask for a histogram of counts with slightly uneven breaks but
histogram() ignores the 'type' argument and provides density scaling
instead.
x = sample(1:3, 100, replace=TRUE)
histogram( ~ x, breaks=c(0,1.5,2.5,3.5), type='count')
My real application has time data with month boundaries for the breaks
and I DO want counts on the y-axis.
A work-around is not difficult but
2009 Feb 18
2
Tables
Are there any standards emerging for how to represent tables in Markdown?
Regards,
- Daniel
--------------------------------------------
Dr Daniel Winterstein
Winterwell Associates Ltd
tel: 0772 5172 612
http://www.winterwell.com
Registered in Scotland, company no. SC342991
2012 Jun 19
2
Thinking Sphinx Problem
Hi,
I am using *Thinking Sphinx version 2.0.11 *in one of my project. To create
an index I ran* **rake thinking_sphinx:index *and I got the following error
Generating Configuration to /home/saidev/Ubuntu
One/burgundy/ssearch/config/development.sphinx.conf
rake aborted!
At least one field is necessary for an index
Tasks: TOP => thinking_sphinx:index
(See full trace by running task with
2009 Feb 16
1
Adjusting the Axis in a histogram to the prespecified breaks
Hello
I tried a few searches on hist, histogram, equidist and space (space=0 was
mentioned in one contribution), but none of that so far worked. It also says
in the help "##-- For non-equidistant breaks, counts should NOT be graphed
unscaled:" - which is precisely what I am looking for, but I cannot find it.
I want to make a histogram using breaks which are spaced exponentially and
in
2010 Apr 16
1
histogram breaks
===============================
Q2=c(
+ sample(10:19,8,T),
+ sample(20:24,15,T),
+ sample(25:29,25,T),
+ sample(30:39,18,T),
+ sample(40:49,12,T),
+ sample(50:64,7,T),
+ sample(65:89,5,T)
+ )
================================
hist(Q2)
can give me a histogram,
however, how do i get a different 'breaks'?
i want to be break down into the intervals
as my 'sample'?
i.e. the 1st
2009 Mar 28
1
Breaks in y-axis of histogram using lattice
Hello R-Users,
I am plotting several histograms to demonstrate zero-inflated data using
lattice. Because there are so many zeros, it is difficult to see the
observations of non-zeros on the graph (i.e. the y-axis scale is too
large). I would like to break the y-scale so that the non-zeros at
least show up on the graph. Below is an example of the code for the
histogram (e.g. I have several
2008 Aug 27
1
Odd behavior in histogram breaks?
I am looking at histogram breaks, and notice something odd:
> foo <- hist(runif(10000),breaks=20)
> length(foo$breaks)
[1] 21
This makes sense to me.
> foo <- hist(runif(10000),breaks=200)
> length(foo$breaks)
[1] 201
This also makes sense.
BUT
> foo <- hist(runif(10000),breaks=250)
> length(foo$breaks)
[1] 201
> foo <- hist(runif(100000),breaks=250)
>
2012 Jul 02
4
R sub query
Hello,
I would like to substitute a substring of characters defined by a specific start and end sequence.
i.e. in the example matrix below, I would like to substitute ".:X:" with "", where X varies in sequence...
m<-matrix(c(".:0:0,0", ".:2:0,2", ".:194:193,1", ".:56:0,56", ".:58:50,8", ".:13:0,13",
2010 Jan 28
1
Setting breaks for histogram of dates
Hi,
I have a list of dates like this:
date
2009-12-03
2009-12-11
2009-10-07
2010-01-25
2010-01-05
2009-09-09
2010-01-19
2010-01-25
2009-02-05
2010-01-25
2010-01-27
2010-01-27
...
and am creating a histogram like this
t <- read.table("test.dat",header=TRUE)
hist(as.Date(t$date), "years", format = "%d/%m/%y", freq=TRUE)
2000 Oct 25
1
problem with "breaks" in histogram (PR#710)
Full_Name: Matthew Wiener
Version: 1.1.1
OS: linux
Submission from: (NULL) (156.40.248.102)
I've come across a glitch in hist. I can reproduce it on linux for Intel, linux
for
PPC, and Irix 6.5.
t1 <- c(41, 42, 42, 43, 43, 43, 44, 44, 45, 46)
hist(t1, breaks = 10) (OK)
hist(t1/50, breaks = 10)
Error in hist.defauilt(t1/50, breaks = 10):
some 'x' not counted; maybe
2003 Jul 03
4
Generating a vector for breaks in a histogram
Hi
I have two lots of numbers which I would like to histogram using the hist() function. For comparative reasons, I want them to be on the same scale, which I can use the xlim and ylim options to achieve.
However, having them on the same scale is meaningless unless they have the same "breaks". Consulting the documentation, there are 4 ways of defining the number of breaks, only one
2010 Mar 02
1
how to import map data (maptools?) from a html set of 'coords'
Dear R users,
I would like to draw map and import it in maptools/spatstat packages.
The 'raw data' I have come from a web page (<map>...</map>) and are
basically a list of coordinates of a polygon.
I would like to know how to import them in R; I checked the maptools
packages, but all the examples use existing .dbf files.
I just have a (serie of) text file(s) looking like