Displaying 20 results from an estimated 378 matches for "shanes".
Did you mean:
shane
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 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
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
>
2007 Aug 01
3
Test Rendering nothing in Rails
Hi
In a controller I have method that is accessed via an AJAX call and
will conditionally do:
render :nothing => true
to test the condition hitting this line I was hoping to do something
like:
response.should render_template(:nothing)
How should I test this behaviour?
Cheers
Shane
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
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"),
>
2007 Oct 02
4
align the runner
I saw from the thread "color output" that there is a plan to "align
the runner". Is there a place to see what that means? I am just
curious.
Thanks
Shane
2013 Sep 26
1
R not ploting lines in the correct order
Hi,
I have a set of x, y points where x represents dates and y actual values. I
am trying to plot a line graph of the data with points on top, but R is
connecting the wrong points with lines. Does anyone know how I can rectify
this. Please see sample below:
x=
24/09/2009 09:13 16/10/2009 11:17 24/10/2009 21:43 11/09/2009
18:34 22/08/2009
15:45 10/08/2009 00:30 14/08/2009 14:52 24/09/2009
2006 Jan 18
5
Perform action after in-place edit
I want to be able to call an action after performing an edit using the
in-place editor macro. I want to update multiple divs so I was
thinking about using an RJS template. However, I can''t figure out how
to trigger another action after the method created by
in_place_edit_for runs. Is there is an option on Ajax.InPlaceEditor
where I can inject some Element.update calls?
Thanks,
Shane
2007 Sep 20
4
issues submitting a search form
Hello to the list and thanks to Aaron for the cool software.
I''ve been fooling around with Mechanize and Hpricot for a couple of
days and from the docs I''ve read, the following code SHOULD work but
doesn''t. I''ve tried the same code on a couple of different sites and I
get the same exception for each. Any pointers or suggestions are
appreciated.
2012 Apr 19
5
Xen on EC2 | Debian Squeeze AMD 64
Hello ! I''m trying to run Xen on a EC2 AMI
debian-6.0-squeeze-base-x86_64-20110417 (ami-35b68141)
Following this how-to
http://www.howtoforge.com/paravirtualization-with-xen-4.0-on-debian-squeeze-amd64
After installing the packages, I get :
uname -a
Linux ip-10-241-22-60 2.6.32-5-xen-amd64 #1 SMP Tue Mar 8 00:01:30 UTC 2011
x86_64 GNU/Linux
uname -r
2.6.32-5-xen-amd64
Then I do :
2013 Jun 26
3
XYZ data
I have x, y, z data. The x, y fields dont change but Z does. How do I add a
very small number onto the end of each x, y data point.
For example:
Original (X) Original (Y) Original (Z)
15 20 30
15 20 40
New (X) New (Y)
2007 Jan 12
5
Integration Testing - Wait, Watir, or Selenium
I''m evaluating what to use for integration testing:
SafariWatir
- integrates nicely with RSpec
- doesn''t work with Ajax because of Safari event firing issues
Selenium
- Works with Ajax
- doesn''t integrate with RSpec
What is the best guess timeframe for RSpec integration testing?
Will it be able to test Ajax application in the early iterations?
Thanks,
Brian Yamabe
2004 Jan 05
2
pam_winbind problems
Hello,
I am have some interesting problems with the pam_winbind portion of samba
3.1. wbinfo -u and getent passwd
works but when I login I get the following messages in /var/log/messages.
Jan 5 11:09:36 hermes pam_winbind[9014]: write to socket failed!
Jan 5 11:09:36 hermes pam_winbind[9014]: internal module error (retval = 3,
user = `CSQ+shane'
Jan 5 11:09:36 hermes PAM_pwdb[9014]: check
2007 Nov 21
2
When you sometimes wonder how to test this??
Hi
Just something that I have been finding very helpful sometimes when I
am stuck with "how could I test this?" moments is looking at the
Rails test suite.
At the moment I am working on testing our custom error_messages_for
methods and I have found looking at how the Rails tests in
active_record_helper work helpful :-)
So just thought I''d share that. Have
2011 Aug 31
3
Converting anova/ancova summary to data frame
Hi!
Can anyone tell me how to convert the anova/ancova summary output into a data frame?
Thanks!
Shane Phillips
[[alternative HTML version deleted]]
2006 Aug 06
2
Acts as Most Popular plugin
Make your models feel like they are in high school again. This plugin
retrieves the most frequently occurring values for each column. It
adds methods of the form most_popular_[pluralized_column_name]. Check
out
<http://shanesbrain.net/articles/2006/08/04/acts-as-most-popular-rails-plugin>
for sample usage.
The plugin is mostly just a group_by in disguise. It is probably
overkill if you just need to find the most popular items for one
column, and probably doesn''t warrant a plugin. But if you are a
newbie,...
2007 Aug 21
1
Extremely slow file serving
Shane,
Please see my Bug nr 488:
https://bugzilla.samba.org/show_bug.cgi?id=4889
I've experienced a few strange things I can't explain.
Does the copy go faster when you access an other (random) file on
your share?
are you able to do make a copy from a share with the client in a
vmware session on the same samba server?
Regards,
Gaston
Op 21-aug-2007, om 6:29 heeft Shane het
2013 Mar 26
6
How do I show real values on a log10 histogram
Hi,
I have a histogram with values logged to the base 10
hist(log10(x),breaks=60)
How do I show the log values on the x-axis and a second x-axis showing the
real values?
Thanks
--
Shane
[[alternative HTML version deleted]]
2008 Jan 10
3
Two Asterisk Boxes Playing Together
Okay, here's the dal.
Me and my friend both have asterisk boxes. I want to be able to type
extension 27 on my end and get his extension 27, and he wants to be
able to type 277 on his end and get my extension 9999. We both have
FQDN's, and would like to see about doing this either over sip or
IAX...
Any help much papreciated,
Shane
--
-Shane
Blog: http://blind-geek.com/blog/
CoOwner: