Displaying 20 results from an estimated 500 matches similar to: "Curiously short cycles in iterated permutations with the same seed"
2017 Dec 08
0
Curiously short cycles in iterated permutations with the same seed
Hi Boris,
Do a search on "the order of elements of the symmetric group". (This search
will also turn up homework questions and solutions.) You will understand
why you are seeing this once you understand how a permutation is decomposed
into cycles and how the order relates to a partition of n (n=10 in your
case).
Enjoy!
Eric
On Fri, Dec 8, 2017 at 6:39 AM, Boris Steipe <boris.steipe
2014 Sep 08
3
problema con los cambios de marcas temporales en el eje X
Muchísimas gracias Carlos, de verdad que te agradezco la ayuda, pero no es lo que voy buscando. Quiero colocar en el eje de abscisas la secuencia temporal de los meses, es decir, agosto septiembre, octubre, etc? pero no las fechas de las toma de datos, sino que aparezca la marca de un mes, y la siguiente marca sea la del siguiente mes, etc?, y además que las muestras estén separadas de acuerdo con
2014 Sep 08
2
problema con los cambios de marcas temporales en el eje X
Muchas gracias Carlos, previo a mi correo, entre las pruebas que hice estaba una parecida a la que apuntas de la siguiente manera:
attach (Libro1)
plot (xbar~as.Date(fechas,"%d/%m/%y"), ylim=c(400,660), xaxt="n", type="b", pch=19,cex=1)
xlabels<-strptime(fecha,format="%d/%m/%Y")
axis.Date (1,at=xlabels,format="%b-%y")
2010 May 13
1
cdplot() with 'POSIXct' x
Hi,
Given that cdplot() is used to produce the conditional density of a
categorical y along a numerical x, it seems natural that it could be
used with a date or time x (such as 'POSIXct'). Is this desirable? If
so, I've created a patch that would allow this, by coercing the POSIXct
x variable to produce the density, but use the original POSIXct x to
draw the x axis.
Index:
2017 Sep 25
2
Subset
myDF <- data.frame(a = c("<0.1", NA, 0.3, 5, "Nil"),
b = c("<0.1", 1, 0.3, 5, "Nil"),
stringsAsFactors = FALSE)
# you can subset the b-column in several ways
myDF[ , 2]
myDF[ , "b"]
myDF$b
# using the column, you make a logical vector
! is.na(as.numeric(myDF$b))
# This can be used to select the
2017 Jun 28
4
Nash equilibrium and other game theory tools implemented in networks using igraph or similar
I responded to the unhelpful suggestion "Why don't you implement and uplad the package to CRAN?" No mention of a search engine. Is this what you are commenting on Jeff?
> On Jun 28, 2017, at 5:41 AM, Jeff Newmiller <jdnewmil at dcn.davis.ca.us> wrote:
>
> In what way does reminding people that packages exist because others just like them contributed something
2017 Sep 25
1
Subset
Always via logical expressions. In this case you can use the logical expression
myDF$b != "0"
to give you a vector of TRUE/FALSE
B.
> On Sep 25, 2017, at 8:00 AM, Shane Carey <careyshan at gmail.com> wrote:
>
> This is super, really helpfull. Sorry, one final question, lets say I wanted to remove 0's rather than NAs , what would it be?
>
> Thanks
>
2023 Jul 22
2
plotly
ChatGPT-4:
------ Query: ----------------------------------
Thank you. The `value` in the code example is 2874. The plot shows a large number at the center and a smaller value computed as a delta relative to the `reference` of 4800. But the large value is given as 2870, and the smaller value is given as -1930 i.e. both values are rounded. Can I control the precision of these two numbers?
2017 Sep 22
3
Subset
Super,
Thanks
On Fri, Sep 22, 2017 at 4:57 PM, Boris Steipe <boris.steipe at utoronto.ca>
wrote:
> > a <- c("<0.1", NA, 0.3, 5, "Nil")
> > a
> [1] "<0.1" NA "0.3" "5" "Nil"
>
> > b <- as.numeric(a)
> Warning message:
> NAs introduced by coercion
> > b
> [1] NA NA 0.3
2018 Mar 21
2
Sum of columns of a data frame equal to NA when all the elements are NA
No. The empty sum is zero. Adding it to another sum should not change it. Nothing audacious about that. This is consistent; other definitions just cause trouble.
-pd
> On 21 Mar 2018, at 18:05 , Boris Steipe <boris.steipe at utoronto.ca> wrote:
>
> Surely the result of summation of non-existent values is not defined, is it not? And since the NA values have been _removed_,
2017 Nov 18
3
Complicated analysis for huge databases
The loop :
AllMAFs <- list()
for (i in length(SeparatedGroupsofmealsCombs) {
AllMAFs[[i]] <- apply( SeparatedGroupsofmealsCombs[[i]], 2, function(x)maf( tabulate( x+1) ))
}
gives these errors (I tried this many times and I'm sure I copied it entirely) :-
Error in apply(SeparatedGroupsofmealsCombs[[i]], 2, function(x) maf(tabulate(x + :
object 'i' not found
> }
2017 Sep 25
0
Subset
This is super, really helpfull. Sorry, one final question, lets say I
wanted to remove 0's rather than NAs , what would it be?
Thanks
On Mon, Sep 25, 2017 at 12:41 PM, Boris Steipe <boris.steipe at utoronto.ca>
wrote:
> myDF <- data.frame(a = c("<0.1", NA, 0.3, 5, "Nil"),
> b = c("<0.1", 1, 0.3, 5, "Nil"),
>
2017 Nov 18
0
Complicated analysis for huge databases
> On Nov 18, 2017, at 1:52 AM, Allaisone 1 <allaisone1 at hotmail.com> wrote:
>
> Although the loop seems to be formulated correctly I wonder why
> it gives me these errors :
>
> -object 'i' not found
> - unexpected '}' in "}"
You probably did not copy the entire code offered. But we cannot know since you did not "show your code",
2017 Nov 18
2
Complicated analysis for huge databases
Although the loop seems to be formulated correctly I wonder why
it gives me these errors :
-object 'i' not found
- unexpected '}' in "}"
the desired output is expected to be very large as for each dataframe in the list of dataframes I expect to see maf value for each of the 600 columns! and this is only for
for one dataframe in the list .. I have around 150-200
2017 Aug 03
0
find similar words in text
Please keep messages on the list so others can pitch in.
_Which_ words do you want to consider identical for the purpose of frequency count?
_What_ do you want to plot?
B.
> On Aug 3, 2017, at 4:36 PM, Riaan Van Der Walt <Riaan.VanDerWalt at nwu.ac.za> wrote:
>
> Hallo Boris,
> I've loaded the Rstem, Snowball.
> But I am clueless how to get a list eg. whal* (whale,
2016 Apr 03
2
row.names(), rownames(), colnames(), names() ...?
The help text for row+colnames {base} states:
"For a data frame, rownames and colnames eventually call row.names
and names respectively, but the latter are preferred."
Why are they "preferred"?
Why is it names(), not col.names()?
I have only ever used names() for vectors - I'm surprised it works on data.frames... IMO this is not great for code readability, thus
2018 Mar 21
0
Sum of columns of a data frame equal to NA when all the elements are NA
I see: consistency with additive identity. That makes sense. Thanks.
B.
> On Mar 21, 2018, at 1:22 PM, peter dalgaard <pdalgd at gmail.com> wrote:
>
> No. The empty sum is zero. Adding it to another sum should not change it. Nothing audacious about that. This is consistent; other definitions just cause trouble.
>
> -pd
>
>> On 21 Mar 2018, at 18:05 , Boris
2017 Jun 28
0
Nash equilibrium and other game theory tools implemented in networks using igraph or similar
Thanks I too wondered about the tone. The first suggestion was that I
should "google it" and the second, write my own code. I think if I did I'd
be reinventing the wheel, (and it'd be a big challenge for me). Also, I
have been searching and not found such code, despite evidence that it has
been coded (just not sure if it was in R). BTW I did write to authors of
the article I
2018 Mar 21
1
Sum of columns of a data frame equal to NA when all the elements are NA
"I see: consistency with additive identity. "
Ummm, well:
> 1+NULL
numeric(0)
> sum(1,NULL)
[1] 1
Of course, there could well be something here I don't get, but that doesn't
look very consistent to me. However, as I said privately, so long as the
corner case behavior is documented, which it is, I don't care.
Cheers,
Bert
Bert Gunter
"The trouble with
2017 Sep 25
0
Subset
Hi,
Lets say this was a dataframe where I had two columns
a <- c("<0.1", NA, 0.3, 5, "Nil")
b <- c("<0.1", 1, 0.3, 5, "Nil")
And I just want to remove the rows from the dataframe where there were NAs
in the b column, what is the syntax for doing that?
Thanks in advance
On Fri, Sep 22, 2017 at 5:04 PM, Shane Carey <careyshan at