LaTeX

 

p' = \frac{w_{AA}p^2 + w_{Aa}pq}{w_{AA}p^2 + w_{Aa}pq + w_{aa}q^2}
 

This semester, one of my classes has required me to turn in all of my assignments in LaTeX. LaTeX (la-tek) is built on TeX, a typesetting language meant to produce beautiful documents reminiscent of the days when papers were printed from engraved plates. Typesetting was an art that got lost in the digital age.

When I first got the news that assignments were to be handed in using LaTeX, I admit I was a bit worried. The assignments were already going to be difficult enough since it is a bioinformatics class working with data types I have not been used to dealing with. On top of that, I’d have to learn a new system for typing up my homework. It has been a pain in the butt, but it has also been fun and pretty useful. One of the big advantages of LaTeX is its typesetting of mathematical formulas. It is easy and elegant, once you get used to the syntax. Anyone who has used the Microsoft equation editor that comes with Office knows it is a pain to work with. The point and click interface is slow and clumbsy. The LaTex looks ugly, but it also makes sense. The formula above reads as follows in LaTex:

p’ = \frac{w_{AA}p^2 + w_{Aa}pq}{w_{AA}p^2 + w_{Aa}pq + w_{aa}q^2}

The second advantage of LaTeX is that it can be completely integrated with R, the programming language that I use to analyze data. Natively, R outputs to plain text. But LaTeX integration with Sweave lets me run R code along with the TeX document and output data tables and graphics in a printable format, integrated with text. Plus, if I need to alter the R code, I can do so right in the Sweave document.

Lately, I discovered a LaTeX plugin for wordpress that allows me to make mathematical formulas in LaTeX’s math mode. There’s currently no math typesetting for html, yet the internet is a great resource for learning about math topics. Unfortunately, the LaTex doesn’t integrate as selectable text, but instead is output as an image, but it’s a good start for now. Perhaps I can make some future posts that involve some mathematical modeling of biological topics.

Since I have been using LaTeX for bioinformatics class, I have been using it to turn in assignments for other classes. It has been a useful medium for typing up Quantitative Genetics problem sets, and the presentation that I’ll be giving at Evo-Wibo in two weeks will be made using LaTeX. At some point, I’ll have to install Lilypond, a typesetting language for producing music notation.

I’m a nerd, and proud of it.

By the way, extra props if you understand the equation at the top of the page.

Similar Posts

  • |

    A Walk Around the Yard

        When you live somewhere long enough and see the same scenery day after day, you sort of become numb to it. It no longer thrills you the way it did when you first moved in. That’s sort of how I feel. Don’t get me wrong, I love my house and its location, but it feels like I could have better scenery out my window living somewhere else. The scenery here is never actually dull. I’ve got a great view of Spud Hill, Deary’s local “mountain” that stands over 1000 feet above the town, and most evenings, we get…

  • Hunter’s Moon

    Havest Moon, originally uploaded by Matthew Singer. I’ve been so busy lately that I haven’t been able to make any new posts. I wish I could tell you that I’ve been busy doing some sort of interesting research, but that’s just not the case yet. However, during my drive home this evening, I was given a nice treat. My drive to and from school is about 25 miles, one way. This is a bit on the long side but nothing that can’t be done. I do sometimes envy those who can get up and walk to school, not using any…

  • Puppies for Sale

    The puppies are now over 8 weeks old and oh so cute. As you can imagine, seven growing pups indoors can create quite a mess that is hard to keep on top of. On top of that, any time you step into their room, they all mob you for attention. So, as spring weather has descended upon the Palouse, we found scrap lumber and fencing and built an outdoor playpen for the dogs. So far it is doing the job. It’s also giving the pups some much needed fresh air and sunshine, which in turn tires them out so all…

  • Flight Paths

    [map style=”width: auto; height:400px; margin:20px 0px 20px 0px; border: 1px solid black;” maptype=”ROADMAP” gpx=”http://www.mineral2.com/wp-content/uploads/Flights.GPX”] If you don’t already know me, I have a thing for maps and geography. It’s an absolute delight to see the landscape from the air. I’ve been bringing my GPS with me when I fly, mostly to keep track of flight progress and to identify what I’m seeing out the window. But it’s also interesting to see how the FAA routes flights. Spoiler Alert: it’s not a direct path between cities. The two tracks above show the flight path between Phoenix and Cancun in both directions….

  • |

    The latest hype in Moscow

    The latest rage in Moscow, Idaho is the sighting of an immigrant that shouldn’t be here. A Northern Hawk Owl (Surnia ulula) has been spotted in Moscow across Rt. 8 from the Safeway parking lot. The earliest sightings on eBird show that this individual has been hanging around since Tuesday, reliably in the same spot. This is an exciting discovery because the Northern Hawk Owl isn’t supposed to be seen this far south. It’s native range is exclusive to Canada, and visits to the United States are few and infrequent. It’s unclear at this time how long the owl will…

  • |

    Fireworks in the Mountains

    A garden update from the last post: I’m happy to announce that the lettuce that the chickens ate down to the soil is growing back quite nicely and will be ready for consumption within a few days. And now on to the main post: Elk River hosts an annual Independence Day celebration they call “Fireworks in the Mountains,” but they don’t necessarily hold it on the 4th of July, but on the weekend before or after if the 4th happens to be mid-week. The event attracts a lot of people and the general store stays open late to sell its…