sorry for the absolutely beginner question here.
I've been looking at the tufte-latex class, specifically the tufte sample book. It makes use of marginfigures, which I believe are provided by the sidenotes package.
As you can see in the book, there is a marginfigure implemented with the code:
\begin{marginfigure}
\includegraphics{file}
\caption{caption}
\end{marginfigure}
However, in my custom class file I use the sidenotes package using
\usepackage{sidenotes}
It should be noted that this works fine, I can use normal sidenotes without any problems.
However, when I go to put in a marginfigure using the code above I get the following error:
Environment marginfigure undefined.
\begin{document} ended by \end{marginfigure}
How can this be fixed so that my marginfigure implements properly.
Sorry for the basic question, but I hadn't found any other fixes.
EDIT 1: Those are the only two errors I have.
All I do is import the package in my class file, then in the document I try to implement marginfigure, but receive the errors above.
Do I need to use any other packages alongside it?
EDIT 2:MWE
\documentclass{article}
\usepackage{sidenotes}
\usepackage{blindtext}
\begin{document}
\blindtext
\begin{marginfigure}
\includegraphics{marginfigure}
\end{marginfigure}
\end{document}
sidenotespackage documentation, themarginfigureexample you provided should work fine. The error you provided is usually preceded by other errors that are more indicative of the cause of the problem. Can you provide us a short document that demonstrates this error? – godbyk May 20 '13 at 00:46\documentclass{...}and ending with\end{document}which reproduces the error/s. In this way documentclass used by you will also be known to others. – texenthusiast May 20 '13 at 01:35marginfigureMargin floats and hyperlinks – cmhughes May 20 '13 at 02:52\listfilesbefore\begin{document}and compile you can see the list of packages and its version used. If my guess is right your's would besidenotes.sty 2011/11/29 v0.81but your MWE compiles well withsidenotes.sty 2012/11/09 v0.92. Hence you may need an update to your TeX distribution ? or use latest version ofsidenotesfrom ctan. Reason:marginfigurefeature is added insidenotesfrom v0.90 as seen in page 6 of Change History – texenthusiast May 20 '13 at 03:58