background preloader

Latex

Facebook Twitter

Short and Complete LATEX presentation. Shravan Vasishth's Slog (Statistics blog): Automating R exercises and exams using the exams package. It's a pain to design statistics exercises each semester, and because students from previous share old exercises with the new incoming students, it's hard to design simple exercises that students haven't already seen the answers to.

Shravan Vasishth's Slog (Statistics blog): Automating R exercises and exams using the exams package

On top of that, some students try to cheat during the exam by looking over the shoulder of their neighbors. Homework exercises almost always involve collaboration even if you prohibit it. It turns out that you can automate the generation of fixed-format exercises (with different numerical answers being required each time). You can also randomly select questions from a question bank you create yourself. And you can even create a unique question paper for each student in an exam, to make cheating between neighbors essentially impossible (even if they copy the correct answer to question 2 from a neighbor, they end up answering the wrong question on their own paper). All this magic is made possible by the exams package in R. 1. 2. Using colours in LaTeX - ShareLaTeX, Online LaTeX Editor. There are several elements in LaTeX whose colour can be changed to improve the appearance of the document.

Using colours in LaTeX - ShareLaTeX, Online LaTeX Editor

Colours can be manually defined to a desired tone using several models, this article explains how. [edit] Introduction The simplest manner to use colours in your LaTeX document is by importing the package color or xcolor. Both packages provide a common set of commands for colour manipulation, but the latter is more flexible and supports a larger number of colour models. Below an example: Create LaTeX tables online.

Templates

Tutorials. Packages. Macros/latex/contrib/fancyhdr/ This is fancyhdr, a replacement for fancyheadings.

macros/latex/contrib/fancyhdr/

I still still intend to make sometime in the future a real .dtx of it, including the minimal documentation. The current documentation is in fancyhdr.tex, but this contains much more material than the fancyhdr doc. When the fancyhdr.dtx is ready, I will rename fancyhdr.tex into something like pagelayout.tex to get it more in line with the title (Page Layout in LaTeX). fancyhdr is 99% compatible with fancyheadings. The only incompatibility is that \headrulewidth and \footrulewidth and their \plain... versions are no longer length parameters, but normal macros (to be changed with \renewcommand rather than \setlength). Although all the other old fancyheadings commands continue to work you are advised to use the new syntax as described in fancyhdr.tex, because this is much easier to use in complicated cases. Files Down­load the con­tents of this pack­age in one zip archive (254.5k).

Latex-decode/features/punctuation.feature at master · inukshuk/latex-decode. Getting to grips with LaTeX - writing. Here are some tutorials I have written for getting up to speed with this excellent document processing system.

Getting to grips with LaTeX - writing

Funnily enough I wouldn't consider myself an expert, per se, but I'm learning all the time. I recall finding it quite taxing when I started to learn LaTeX, which is why I have started these tutorials. However, I hope that my experience plays to your advantage because I cover sort of questions and problems I had when I first learning LaTeX which are probably typical for most beginners. Benefits LaTeX pre-dates modern graphical word processors, if not modern graphical operating systems! For a more detailed account, see my article regarding the numerous advantages. R to Latex packages: Coverage. There are now quite a few R packages to turn cross-tables and fitted models into nicely formatted latex.

R to Latex packages: Coverage

In a previous post I showed how to use one of them to display regression tables on the fly. In this post I summarise what types of R object each of the major packages can deal with. Unsurprisingly, there’s quite some variation… The packages I’m looking at here are: apsrtable (v0.8-8), xtable (v1.7-1), stargazer (v3.0.1), memisc (v0.96-3) and texreg (v1.22). Using Sweave with XeLaTeX. One Pager Performance Report with knitr, R, and a Different Font. \documentclass[nohyper,justified]{tufte-handout} %\documentclass{article} %\usepackage[absolute,showboxes]{textpos} \usepackage{fontspec} \usepackage[absolute]{textpos} \usepackage{sidecap} %\usepackage{color} %\usepackage[usenames,dvipsnames,svgnames,table]{xcolor} %get Open Sans Light from Google Webfonts \setmainfont{Open Sans Light} \begin{document} \pagestyle{empty} <<include=FALSE>>= opts_chunk$set(concordance=TRUE, dev="tikz") \begin{wide}

One Pager Performance Report with knitr, R, and a Different Font

Learn LaTeX - ShareLaTeX guides and knowledgebase. ProTeXt - a TeX distribution for Windows. ProTeXt aims to be an easy-to-install TeX distribution for Windows, based on MiKTeX.

proTeXt - a TeX distribution for Windows

After downloading, a wizard (available in several languages) guides the installation. Download and install You can download the self-extracting protext.exe file from CTAN; it is well over 2GB. That link will automatically choose a nearby CTAN mirror. If problems with the download, please manually choose a mirror from the list. If such a large download is problematic for you, proTeXt is also included in the TeX Collection, which you can get by becoming a TeX user group member. Once you have the distribution, you can start the installation by running Setup.exe (if it does not open automatically). Animated plots in R and LaTeX. Controlling figure and table placement in LaTeX. It can be frus­trat­ing try­ing to get your fig­ures and tables to appear where you want them in a LaTeX doc­u­ment.

Controlling figure and table placement in LaTeX

Some­times, they just seem to float off onto another page of their own accord. Here is a col­lec­tion of tools and ideas that help you get con­trol of those pesky floats. Use the place­ment options: h, t, b and p. For example causes LaTeX to try to fit the float “here”, or at the “top” of the cur­rent page (or the next page), or at the “bot­tom” of the cur­rent page (or the next page). One of the rea­sons that the floats won’t go where you want them is that there are a lot of con­straints on where they can go.

These can all be changed indi­vid­u­ally. If you want to change the defaults, the fol­low­ing val­ues give rea­son­able results: The \clearpage com­mand starts a new page and inserts all floats that have not yet appeared before con­tin­u­ing. Which will put all the floats at the end of the cur­rent page. A very use­ful pack­age is placeins.