User: Pass: | Sign Up | Help

data-driven
college admission predictions






March « 2008 « MyChances.net

Archive for March, 2008

Recursive str_replace in PHP

by James
Thursday, March 20th, 2008
No Gravatar

I was looking for a recursive str_replace in php tonight and I couldn’t find any, so I wrote one. This takes the exact same parameters as str_replace, in the same order. It recursively searches the $subject, replacing $search with $replace, while keeping track of how many times ($count) it has replaced the $subject.


Example:

$count=0;
$string = "; ; I; am; ; ; ; ; become; ; ; ; ; ; ; ; ;";
string = str_replace_recursive('; ;',';',$string,$count);

echo $string;
echo $count;

Outputs:
string --> I; am; become;
count --> 12

(Note that this is not the best code to use for this situation; can you write a faster solution to this example using only plain vanilla str_replace?)

  • Share/Save/Bookmark

Big survey update

by James
Tuesday, March 18th, 2008
No Gravatar

I’m rolling out a big survey update today that should simplify and improve the data that gets collected; as always, this will help with predictions. Expect this around 9:00pm Pacific on Tuesday; I’ll make another note here when the update gets “pushed” out.

Later this week, I’ll be clarifying the privacy policy and beefing up privacy safeguards.

By the way, it looks like MIT has been sending out rejection letters; let me know if you’ve seen any MIT acceptances.

  • Share/Save/Bookmark

Bug in Scriptaculous demo

by James
Monday, March 17th, 2008
No Gravatar

I’ve been updating the site to use Prototype.js, an Ajax framework. In the process, I was looking for some demo code. Scriptaculous, as they often do, came to the rescue. However, they have a bug on their page that deals with the Prototype Ajax.Updater. They say:

(more…)

  • Share/Save/Bookmark

Which schools are GPA-oriented?

by James
Thursday, March 6th, 2008
No Gravatar

Other bloggers have been discussing which schools place the most emphasis on GPA.

At Mychances.net, at least, it’s our experience that the schools at the “top” are the ones most likely to take into account more than GPA and scores. These are the ones most difficult to “chance” based on numbers alone. The ones in the middle of the pack tend to be pretty well predictable based on GPA, standardized tests, and little more than that.

  • Share/Save/Bookmark