Displaying 20 results from an estimated 10242 matches for "schools".
Did you mean:
school
2006 Aug 16
6
read.csv issue
I'm trying to read in some data from a .csv format and have come across
the following issue. Here is a simple example for replication
# A sample .csv format
schid,sch_name
331-802-7081,School One
464-551-7357,School Two
388-517-7627,School Three \& Four
388-517-4394,School Five
Note the third line includes the \ character. However, when I read the
data in I get
>
2004 Nov 29
1
Labeling charts within a loop
Hi All:
This may turn out to be very simply, but I can't seem to add the name of
the school to a chart. The loop I created is below that subsets a
dataframe and creates a chart for each school based on certain
variables. As it stands now, they title includes the school's ID number.
Instead, I want to replace this with the school's actual name, which is
stored in a variable called
2006 Apr 20
4
Question about Associations
Hi all. Got a stupid-simple question about associations. I have two
models - school and course. There are a fixed number of schools (set
up in the migration). Each course is assigned a school and a school
will be associated with multiple courses...
How do I set up the associations? Do (can) I have School :has_one
:course and Course :has_many :schools?
Does the schools table then get a course_id field or the other way around?...
2005 Aug 25
1
question about custom contrasts in ANOVA
Hi,
I have a problem in which I have test score data on students from a number
of schools. In each school I have a measure of whether or not they
received special programming. I am interested in the interaction between
school and attendance to the programming, but in a very select set of
comparisons. I'd like to cast the test as one in which students in each
school who attend...
2006 Jul 31
2
Updating a belongs_to foreign key leaves the old association object available
Perhaps this is intentional, but it seems unlikely:
class Person < ActiveRecord::Base
belongs_to :school
end
p = Person.find(:first)
p.school # nil
p.school_id = School.find_by_name(''High School'').id
p.school.name # High School
p.school_id = School.find_by_name(''Primary School'').id
p.school.name # High School <= Shouldn''t this be Primary
2008 Apr 10
3
Custom Form Builder Help
...ie.caboo.se/178776
It works great, except that the id''s and class names get messed up.
Instead of school_name, I get nilClass_name.
The other methods work fine however.
Here''s the form:
<h1>New School</h1>
<%= show_flash %>
<% af_form_for :school, :url => schools_path, :html => {:method
=> :post } do |f| %>
<%= f.typeahead :name, @schools, "name", "name" %>
<div class=''label''>School Type</div>
<%= f.radio_button :type, "College", :label => "College/
University",...
2008 Sep 17
1
A Simple Question
Hi:
I am trying to run your SCHOOLS example as following and I get an error message stated that : Error: could not find function "bugs"
Would you please help me since I would like to run some WINBUG programs from your R by reading external data and I am new to R?
Do I missing some function? Should I install some extra file...
2006 May 25
10
One set of source code with multiple instances
Hi there, we made a PHP and Impakt2 based web content management system
for schools with specific features that work really well for schools.
The way I designed it was so there was one central set of source code
and an empty (in terms of rows in tables) database structure. To set up
a new school i had a script that basically created a new directory in
/var/www and then within...
2009 Feb 09
3
rendering original view
...nder :xml => @review.errors, :status =>
:unprocessable_entity }
end
end
end
In this view the line
format.html { render :action => "new" }
renders the reviews new method when the validation fails...thing is I
want to show the school and the error messages, (schools controller show
method) like this line, format.html { redirect_to(@school) }.
any help on how to do this?
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails...
2006 Jun 03
8
confused about ActiveRecord relationships
I am very confused about where to put the belongs_to and the has_one
(and other relationship identifiers). I have read the RDoc and the
agile book many times about this and I think i still see it backwards.
Let me outline my app so you have an understanding...
I have 2 tables:
Schools { id, school_name, address_id }
and
Addresses { street1, street2, city, state, zip, country }
*** this is the way that makes sense to me but it doesnt work ******
Models
school.rb
has_one :address
address.rb
belongs_to :school
View for School
<% for school in @schools %>
<...
2011 Jan 13
1
Openbugs and rbugs on mac with wine
Hello list,
I?ve been trying to get OpenBUGS running on my mac using the wine
emulator. I can run Openbugs just fine by doing:
wine ~/OpenBUGS312/OpenBUGS.exe
In the terminal, so OpenBUGS works. When I try to run the schools
example using rbugs(), the OpenBUGS process starts in wine, but it
just sits there, no log, no script, no output of any sort. The rbugs
() call makes the init, data, model and script file, but there seems
to be a problem with R piping the script to OpenBUGS, here is my example
library(rbug...
2008 Jan 31
1
R2WinBUGS is broken
Dear R-users,
I am trying to use the following code to reproduce results from Prof.
Gelman's book, but have the listed error for R2WinBUGS version (the openbugs
version is good). I am using R-2.6.1 on windows XP, and all the R packages
are most current ones. schools.bug can be found at
http://www.stat.columbia.edu/~gelman/bugsR/runningbugs.html . Can anyone
help me to figure out what's going wrong?
rm(list=ls())
library(R2WinBUGS)
library ('BRugs')
setwd('C:/bayesian/bda/codes/example_5_5')
data(schools)
J <- nrow(schools)
y <- scho...
2004 Nov 17
1
"Impossible to run" error message when using Sweave
Dear List:
I have a large dataset of multiple schools. My goal is to produce a
separate tex file for each school that plots some of the student
achievement scores. Essentially, the aim is to develop a custom report
for each school. To accomplish this, I have code for a loop that gets
sourced into R and then Sweaves the multiple files to create the
ind...
2005 May 16
1
A question about bugs.R: functions for running WinBUGs from R
...you please help me out? I am stuck on this for a while and really
frustrated now.
The program and the error as follow.
Thanks a lot in advance!
Jiaa
________________________________________________________________________
_
> # R code for entering the data and fitting the Bugs model for 8
schools
> # analysis from Section 5.5 of "Bayesian Data Analysis".
>
> # To run, the Bugs model must be in the file "schools.txt" in your
working
> # directory and you must load in the functions in the bugs.R file (see
> # http://www.stat.columbia.edu/~gelman/bugsR/).
&g...
2008 Apr 07
5
Associations errors
undefined method `each'' for 0:Fixnum
at line
@school = School.find_by_title(params[:school_id].gsub(''-'', " "))
for team in @school.teams
........
end
@school does exist cause i tried with .find(:first) and it gave the
same error.
Also I''m getting
undefined method `reject'' for #<Game:0x24ca1c4>
From @home.game_ids = @game
2008 Nov 02
2
Merging nested files
Greetings all,
I have three files that I would like to merge. The first is a student
level file that contains the student ID, their school ID, and their
country ID.
The second is the school file that contains the school ID and country ID.
The third is the country file with a country ID.
I would like to merge the three together using the common country ID.
Of course, what this would mean
2006 Feb 10
1
Lmer with weights
...ot;meta" analysis. I wonder if weights
argument is the right one to use to include uncertainty (standard
errors) of "data" into the model. I would like to use lmer(), since I
would like to have a "freedom" in modeling, if this is at all possible.
For example we can take schools data by Gelman from R2WinBUGS package.
As you can see bellow use of weights argument did not had influence on
results.
I do not know if my specification of weights i.e. 1 / sd^2 is ok. Under
least squares one minimizes sum(e^2_i) or sum(w_i * e^2_i) with weighted
LS. If I consider that \sigma_...
2008 Dec 14
2
custom REST action - template question
Hallo phorum,
i have custom rest action.
routes.rb:
map.resources :schools, :collection => { :graduations => :get }
SchoolsController:
def graduations
@schools = School.graduation(true)
end
link somewhere in navigation:
<%= link_to ''Schools with graduation'', graduations_schools_path %>
All works OK for me, but Rails needs (of course) a...
2010 Jul 15
3
Creating Enumerated Variables
Hi,
I am trying to create a variable counting the number of individuals based on
two variables. I am able to do it or one variable, but not two. In SAS I was
able to sort by two variables and use a first. statement to create the
counts based on both. Here is an example:
What I have
ID Age School Grade
1 10 1 98
2 10 2 97
3 10 1 92
4 11 1 90
5 11 1 80
6 11 2 70
7 10 1 80
2015 Jul 13
2
Crear datos aleatorios con restriciones
...rado y
>>>>>> escuela
>>>>>>
>>>>>> Si tengo C=4 divisiones, puedo lograr lo que quiero con este código:
>>>>>>
>>>>>> library(randomNames)
>>>>>> set.seed(6232015)
>>>>>> n.schools <-20
>>>>>> n.grades <- 3
>>>>>> n.classrooms <- 4
>>>>>> total.classrooms <- n.classrooms*n.grades*n.schools
>>>>>>
>>>>>> gen.names <- function(n, which.names = "both", name.order =...