The quantmod package for R is designed to assist the quantitative trader in the development, testing, and deployment of statistically based trading models.
What quantmod IS
A rapid prototyping environment, where quant traders can quickly and cleanly explore and build trading models.
What quantmod is NOT
A replacement for anything statistical. It has no ‘new’ modelling routines or analysis tool to speak of. It does now offer charting not currently available elsewhere in R, but most everything else is more of a wrapper to what you already know and love about the language and packages you currently use.
quantmod makes modelling easier by removing the repetitive workflow issues surrounding data management, modelling interfaces, and performance analysis.
Category: Link
Help Changing the Throttle Cable on a C10
When observing the bike from the RH side, rotate the center cable mechanism CW so the carbs are at full throttle. This will bring the “pull” cable access “notch” so it faces the rear of the bike, and more accessible from the top. During the time you are rotating the mechanism, pay attention to the individual carb linkages and you will see a gap form between a stop and a section of the linkage. When the carbs are at full throttle, find a suitable flat blade screw driver and wedge it in this gap to hold the carbs open once you’ve released the cable mechanism. This will give you ample time to fiddle with getting the cable end in the hole and engaged. A pair of long, long-nosed needle nose pliers, or a long hemostat works best in getting the cable end in place.
Via COG.
Exemple Complet Minimal
This is a French acronym used by some mailing list members; it stands for “Exemple Complet Minimal”, or “Complete Minimal Example”. The term refers to test files that can reliably reproduce a bug with the minimal amount of code.
Seal the wiring deal
use butt connectors, ring terminals, and spade clips ad a good crimper. Before crimping, I’ll coat the wire end and the connector with a dielectric paste, avoiding silicon sealer, as it can shrink and allow moisture in. A layer of heat-shrink tubing guarantees a water tight worry free connection.
Nice example of converting wide to tall data with tidyr
> x <- structure(c(1961, 1961, 1961, 1961, 1, 1, 1, 1, 1, 2, 3
+ , 4, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14
+ , 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27
+ , 28, 29, 30, 31, 32, 33, 34, 35, 36)
+ , .Dim = c(4L, 12L)
+ , .Dimnames = list(NULL, c("year", "month", "day", "A", "B", "C"
+ , "D", "E", "F", "G", "H", "I"))
+ )
> xdf <- as.data.frame(x)
> xdf
year month day A B C D E F G H I
1 1961 1 1 1 5 9 13 17 21 25 29 33
2 1961 1 2 2 6 10 14 18 22 26 30 34
3 1961 1 3 3 7 11 15 19 23 27 31 35
4 1961 1 4 4 8 12 16 20 24 28 32 36
> require(tidyr)
> require(dplyr)
> xdf %>% gather(station, discharge, -year, -month, -day)
year month day station discharge
1 1961 1 1 A 1
2 1961 1 2 A 2
3 1961 1 3 A 3
4 1961 1 4 A 4
5 1961 1 1 B 5
6 1961 1 2 B 6
7 1961 1 3 B 7
8 1961 1 4 B 8
9 1961 1 1 C 9
10 1961 1 2 C 10
11 1961 1 3 C 11
12 1961 1 4 C 12
13 1961 1 1 D 13
14 1961 1 2 D 14
15 1961 1 3 D 15
16 1961 1 4 D 16
17 1961 1 1 E 17
Formatting your signature for news posts
If you like, read RFC 3676:
There is a long-standing convention in Usenet news
which also commonly appears in Internet mail of
using “– ” as the separator line between the body
and the signature of a message.
Via help-gnu-emacs.
Announce: PicoLisp in Hardware (PilMCU)
PilMCU is an implementation of 64-bit PicoLisp directly in hardware. A
truly minimalistic system. PicoLisp is both the machine language and the
operating system:
Via help-gnu-emacs.
R Online Anywhere
R-Fiddle lets you run ℝ anywhere with web access.
Other R Engines
R Markdown
R Markdown is an authoring format that enables easy creation of dynamic documents, presentations, and reports from R. It combines the core syntax of markdown (an easy-to-write plain text format) with embedded R code chunks that are run so their output can be included in the final document. R Markdown documents are fully reproducible (they can be automatically regenerated whenever underlying R code or data changes).