A personal diary of DataFrame munging over the years.
Convert Series datatype to numeric (will error if column has non-numeric values)
(h/t @makmanalp)
# The following comments fill some of the gaps in Solargraph's understanding of | |
# Rails apps. Since they're all in YARD, they get mapped in Solargraph but | |
# ignored at runtime. | |
# | |
# You can put this file anywhere in the project, as long as it gets included in | |
# the workspace maps. It's recommended that you keep it in a standalone file | |
# instead of pasting it into an existing one. | |
# | |
# @!parse | |
# class ActionController::Base |
A personal diary of DataFrame munging over the years.
Convert Series datatype to numeric (will error if column has non-numeric values)
(h/t @makmanalp)
http://phpconfigure.com/ | |
See before: | |
compile.mysql5.6.12.txt & compile.apache2.4.4.txt | |
Compile php 5.3.25 | |
sudo mkdir /usr/local/php | |
sudo mkdir /usr/local/php/php_5.3.25 |
require 'spec_helper' | |
# Bustle is a pubsub system used for activity streams: | |
# https://github.com/fredwu/bustle | |
# | |
# Here when a person follows another (or a discussion, for instance), the observer wires | |
# up pubsub between them for future activity notifications. The Follow model knows nothing | |
# about the implementation choices for the pubsub system. | |
describe FollowObserver do | |
subject { FollowObserver.instance } |
group :tools do | |
gem "guard" | |
gem "guard-bundler" | |
gem "guard-rspec" | |
#For detecting changes in the filesystem | |
gem 'rb-inotify', :require => false | |
gem 'rb-fsevent', :require => false | |
#For displaying notices |
/* | |
Simple example that takes a command line provided serial port destination and routes the output to a file of the same name with .log appended to the port name. | |
usage: node logger.js /dev/tty.usbserial <baudrate> | |
*/ | |
var SerialPort = require("serialport"); | |
var fs = require("fs"); | |
var port = process.argv[2]; |
The Basic Key/Value Store | |
------------------------- | |
Extensions now have access to a simple key/value store. To use it require the "storage" module: | |
var storage = require("storage"); | |
// put an object in the store | |
storage.put("my-key", {title: "An object", text: "You can store any normal js object in the store}); |
This is a simple calendar extension using Webpop's search API to list events.
To use the extension create a Section with entries enabled and configure the entries to have a "date" field.
Add calendar.js to your extensions folder and set the calendar section to use this extension.
In the template used to display the calendar section, you can list all future events like this:
Index: sapi/cli/config.w32 | |
=================================================================== | |
--- sapi/cli/config.w32 (revision 308839) | |
+++ sapi/cli/config.w32 (working copy) | |
@@ -6,7 +6,8 @@ | |
ARG_ENABLE('cli-win32', 'Build console-less CLI version of PHP', 'no'); | |
if (PHP_CLI == "yes") { | |
- SAPI('cli', 'php_cli.c', 'php.exe'); | |
+ SAPI('cli', 'php_cli.c php_http_parser.c php_cli_server.c', 'php.exe'); |