Re: [R] 'R' and 'Yield to Maturity'

2010-02-01 Thread Craig P. Pyrame
Madhavi Bhave wrote: Dear R helpers I am calculating the 'Yield to Maturity' for the Bond with following characteristics. Its a $1000 face value, 3 year bond with 10% annual coupon and is priced at 101. The yield to maturity can be calculated after solving the equation - 1010 = [100 /

Re: [R] 'R' and 'Yield to Maturity'

2010-02-01 Thread Craig P. Pyrame
. That was really superb. Madhavi --- On Mon, 1/2/10, S Ellison s.elli...@lgc.co.uk wrote: From: S Ellison s.elli...@lgc.co.uk Subject: Re: [R] 'R' and 'Yield to Maturity' To: Craig P. Pyrame crap...@gmail.com, Madhavi Bhave madhavi_bh...@yahoo.com Cc: r-help@r-project.org Date: Monday, 1 February

[R] Suppress output from getGEO

2010-01-29 Thread Craig P. Pyrame
Dear R-ers, I am using getGEO to download expression data from the Gene Expression Omnibus. With default settings, when a file is downloaded and parsed, lots of dotted lines are printed in the terminal, like this: .. .. .. .. .. .. ..

Re: [R] Suppress output from getGEO

2010-01-29 Thread Craig P. Pyrame
Duncan Murdoch wrote: getGEO is a Bioconductor package. Feel free to insult the helpful people there if you want to alienate them, but please don't crosspost here. Duncan Murdoch Duncan, Do you consider this sort of output from a function helpful in any way? I don't, and I can't see

[R] [Fwd: Re: Suppress output from getGEO]

2010-01-29 Thread Craig P. Pyrame
Original Message Subject:Re: [R] Suppress output from getGEO Date: Fri, 29 Jan 2010 10:29:54 -0500 From: Duncan Murdoch murd...@stats.uwo.ca To: Craig P. Pyrame crap...@gmail.com References: 4b62f906.90...@gmail.com 4b62fb32.4040...@stats.uwo.ca 4b62fe12.7040

Re: [R] Question about creating lists with functions as elements

2009-07-01 Thread Craig P. Pyrame
Dear Duncan and Rolf, That's funny! Thanks a lot. Best regards, Craig Duncan Murdoch wrote: On 30/06/2009 5:11 PM, Craig P. Pyrame wrote: Dear Rolf, What do you mean? He was talking about the fortunes package. Install it, type fortune(), and you'll get a fortune cookie message. Maybe

[R] Question about creating lists with functions as elements

2009-06-30 Thread Craig P. Pyrame
Dear list, I am trying to construct a list of functions using rep. I can't understand the following: c(character, character) = list with two functions rep(character, 2) = error The error says that object of type 'special' is not subsettable, and I have no idea what this means. Would you

Re: [R] Question about creating lists with functions as elements

2009-06-30 Thread Craig P. Pyrame
type as 'x' (except that 'rep' will coerce pairlists to vector lists). So, you can do: rep(list(character), 2) On Tue, Jun 30, 2009 at 9:00 AM, Craig P. Pyrame crap...@gmail.com mailto:crap...@gmail.com wrote: Dear list, I am trying to construct a list of functions using rep. I

Re: [R] Question about creating lists with functions as elements

2009-06-30 Thread Craig P. Pyrame
Dear Barry, Thank you for the suggestion, it does work. I think the documentation might be improved, but it's probably not a good idea to submit bug reports just because I misunderstand what R does. Best regards, Craig Barry Rowlingson wrote: On Tue, Jun 30, 2009 at 1:00 PM, Craig P.

Re: [R] Question about creating lists with functions as elements

2009-06-30 Thread Craig P. Pyrame
Dear Rolf, What do you mean? Best regards, Craig Rolf Turner wrote: On 1/07/2009, at 12:34 AM, Craig P. Pyrame wrote: ... it's probably not a good idea to submit bug reports just because I misunderstand what R does. Gotta be a fortune!!! cheers, Rolf

Re: [R] How to avoid ifelse statement converting factor to character

2009-06-26 Thread Craig P. Pyrame
Stavros Macrakis wrote: On Thu, Jun 25, 2009 at 12:47 PM, Craig P. Pyramecrap...@gmail.com wrote: The man page Stavros quotes states that the class attribute of the result is taken from 'test', which clearly is not the case: Actually, the behavior is documented pretty clearly:

Re: [R] How to avoid ifelse statement converting factor to character

2009-06-26 Thread Craig P. Pyrame
to learn more from the manuals. Best regards, Craig -s On 6/26/09, Craig P. Pyrame crap...@gmail.com wrote: Stavros Macrakis wrote: On Thu, Jun 25, 2009 at 12:47 PM, Craig P. Pyramecrap...@gmail.com wrote: The man page Stavros quotes states that the class attribute

Re: [R] How to avoid ifelse statement converting factor to character

2009-06-26 Thread Craig P. Pyrame
Dear Peter, Thank you for the explanations. Some further questions are inlined below. Best regards, Craig Peter Dalgaard wrote: Craig P. Pyrame wrote: Stavros Macrakis wrote: It gives me a headache, too! I think you'll have to wait for a more expert user than me to supply explanations

Re: [R] How to avoid ifelse statement converting factor to character

2009-06-25 Thread Craig P. Pyrame
Dear Rolf, Rolf Turner wrote: On 25/06/2009, at 12:27 PM, Craig P. Pyrame wrote: Dear Stavros, What you discuss below is somewhat scary to me as an R newbie. Is this just an incident, a bug perhaps, or rather the way things typically go in R, as your Welcome to R! seems to suggest? I

Re: [R] How to avoid ifelse statement converting factor to character

2009-06-24 Thread Craig P. Pyrame
Dear Stavros, What you discuss below is somewhat scary to me as an R newbie. Is this just an incident, a bug perhaps, or rather the way things typically go in R, as your Welcome to R! seems to suggest? I have just started to learn R, and my initial euphoria of the I can do anything with