LaTeX forum ⇒ WinEdtHELP! URGENT!

Information and discussion about WinEdt, a commercial integrated LaTeX environment for Windows
Posts: 3
Joined: Thu May 21, 2015 11:31 am


Postby Alan » Thu May 21, 2015 11:52 am

I ave recently purchased WinEdt 9.0 along with a new Lenovo laptop that I am running Windows 7 on. I am able to compile articles (tex to pdf) but am unable to compile a prosper slide file. When I tried to compile it asked if I would allow the computer to download and install a collection of style files. I said yes to all. Then, I hit the pdfT icon and it went into the green circle loop, saying that the console was in pdfTexify. It circled for many many minutes but eventually I received an indecipherable error compilation report with 4 errors and 3 warnings. One says "I couldn't open the file name ____.aux, another says permission denied for _____.log. I can't even see any other errors listed in the compilation. I am sure it is something simple but have no idea what to do. I am pasting below the prosper file, longer than you need but I did not bother shortening it. Please help - I desperately need to prepare some slides for a presentation in a few days. Thanks, Alan
\newcommand{\blam}{ \mbox{\boldmath $ \lambda $} }
\newcommand{\bOmega}{ \mbox{\boldmath $ \Omega $} }
\newcommand{\bet}{ \mbox{\boldmath $ \eta $} }
\newcommand{\bome}{ \mbox{\boldmath $ \omega $} }
\newcommand{\bbet}{ \mbox{\boldmath $ \beta $} }
\newcommand{\bbeta}{ \mbox{\boldmath $ \beta $} }
\newcommand{\balph}{ \mbox{\boldmath $ \alpha $} }
\newcommand{\balpha}{ \mbox{\boldmath $ \alpha $} }
\newcommand{\bphi}{ \mbox{\boldmath $\phi$}}
\newcommand{\bzeta}{ \mbox{\boldmath $\zeta$}}
\newcommand{\bkap}{ \mbox{\boldmath $\kappa$}}
\newcommand{\bkappa}{ \mbox{\boldmath $\kappa$}}
\newcommand{\beps}{ \mbox{\boldmath $\epsilon$}}
\newcommand{\bepsilon}{ \mbox{\boldmath $\epsilon$}}
\newcommand{\bthet}{ \mbox{\boldmath $ \theta $} }
\newcommand{\btheta}{ \mbox{\boldmath $ \theta $} }
\newcommand{\bnu}{ \mbox{\boldmath $\nu$} }
\newcommand{\bmu}{ \mbox{\boldmath $\mu$} }
\newcommand{\bGam}{ \mbox{\boldmath $\Gamma$} }
\newcommand{\bSig}{ \mbox{\boldmath $\Sigma$} }
\newcommand{\bsig}{ \mbox{\boldmath $\sigma$} }
\newcommand{\bSigma}{ \mbox{\boldmath $\Sigma$} }
\newcommand{\bPhi}{ \mbox{\boldmath $\Phi$} }
\newcommand{\bPsi}{ \mbox{\boldmath $\Psi$} }
\newcommand{\bThet}{ \mbox{\boldmath $\Theta$} }
\newcommand{\bTheta}{ \mbox{\boldmath $\Theta$} }
\newcommand{\bDel}{ \mbox{\boldmath $\Delta$} }
\newcommand{\bDelta}{ \mbox{\boldmath $\Delta$} }
\newcommand{\bnabla}{ \mbox{\boldmath $\nabla$} }
\newcommand{\bLam}{ \mbox{\boldmath $\Lambda$} }
\newcommand{\bLambda}{ \mbox{\boldmath $\Lambda$} }
\newcommand{\bgam}{ \mbox{\boldmath $\gamma$} }
\newcommand{\bgamma}{ \mbox{\boldmath $\gamma$} }
\newcommand{\brho}{ \mbox{\boldmath $\rho$} }
\newcommand{\bdel}{ \mbox{\boldmath $\delta$} }
\newcommand{\bdelta}{ \mbox{\boldmath $\delta$} }
\newcommand{\bfeta}{ \mbox{\boldmath $\eta$} }


\newcommand{\bex}{\begin{example} \rm }
\newcommand{\eex}{\rule{5pt}{5pt} \end{example}}
\newcommand{\bdf}{\begin{definition} \rm }
\newcommand{\bthm}{\begin{theorem} \rm }
\newcommand{\balg}{\begin{algorithm} \rm }

\newcommand{\vbar}{\; \rule[-2.5mm]{.2mm}{6mm} \;}

\newcommand{\matern}{\mbox{Mat\'{e}rn }}


\setlength{\oddsidemargin}{0in} \setlength{\textwidth}{6.5in}

\title{Issues in Estimating Biomass}            % for title page
%\subtitle{ your subtitle }      % (optional) for title page
%\author{ Alan E. Gelfand, Michele Guindani, and Sonia Petrone}
%\footnote{Drawn primarily from Gelfand, Schmidt, Banerjee, and Sirmans, Test, 2005 (with discussion)} }            % for title page
%\email{}        % (optional) for title page
%\institution{ISDS, Duke University, M D Anderson Cancer Center, Houston,\\ and Universita' Bocconi, Milan}    % (optional) for title page




%%\begin{slide} {}
%%width=3.0in,height=3.0in] {Pics/}
%width=3.0in,height=3.0in] {Pics/}

%\item Spatial Process Modelling
%\item The Dirichlet Process \item The SDP and $SDP_{K}$ \item Comparison between GP and SDP
%\item The GSDP \item The $GSDP_{K}$ \item Comparison between SDP and GSDP
%\item What is spatial data?
%\item Three flavors
%\item Random observations at specified locations
%\item Random observations associated with areal units
%\item Random locations (Random observations at random locations?)


\item Increasing use of biomass as a measure of carbon stock, energy availability

\item Challenge of estimating total biomass at different scales; tree level, plot level, hectare level, ``per unit area''

\item Effect of \emph{density}

\item Estimating change in biomass; explaining change in biomass

\item Allometry - species, functional type, community


\begin{slide}{Static vs. Dynamic}

\item Static estimation of biomass.  For a given year, over a collection of plots, as with FIA data.  If we have two or more
    censuses for a given plot, we can estimate change in biomass

    \item Dynamic estimation of biomass.  With annual data as in, e.g., Duke Forest, Coweeta, Hubbard Forest, we can build a
        model for $\Delta$-biomass




\item At tree level, conversion from diameter to biomass

\item $B= \alpha D^{\beta} \equiv g(D) $ so log$B = \alpha + \beta D$

\item Richer forms, nonlinear, using tree height

\item Species specific relationship, aggregating species

\item \emph{Mean} behavior, where to add noise, how much noise

\item Summing for $B_i$, With sample of diameters, $\{D_{ij}\}$, we need $\sum_{j} g(D_{ij}) \neq g(\sum_{j} D_{ij})$



    \item Let $b(x)$ be the individual level biomass associated with a tree of diameter $x$.

    \item Let $B= \sum_{i=1}^{N} b(x_i)$ be the total biomass associated with a plot having $N$ trees.  $N$ varies over
        plots but all plots assumed the same size and $B$ is a realization of total biomass per this plot size

    \item How does $E(b(x))$ behave with $N$? How does var$(b(x))$ behave with $N$? How does $CV(b(x))$ behave with $N$?

    \item How does $E(B)$ behave with $N$? How does var$(B)$ behave with $N$? How does $CV(B)$ behave with $N$? The

    \item $E(B) = N E(b(x))$, var$(B) = N var(b(x))$ (indep), $CV(B) = \frac{1}{\sqrt{N}} CV(b(x))$ (indep)

    \item A \textbf{KEY} point  - do at level of species or functional type but ``density'' would be across all species on
        the plot


\begin{slide}{Anticipated behaviors}

\item For a plot of a given area, more per individual biomass with less dense plot. $\mu_i \downarrow$ as $N_i \uparrow $.

\item For a plot of a given area, more per individual variability in biomass with less dense plot.  $\sigma_{i}^{2}
    \downarrow$ as $N_i \uparrow $.

    \item Also of interest is $CV_{i} = \frac{\sigma_{i}}{\mu_{i}}$ vs $N_i$

    \item How does $N_i$ behave over plots of a given area?

    \item For a plot, if $B_{i}$ is total biomass, how does expected total biomass, $E(B_i) = N_i \mu_i$  behave?

    \item For a plot, how does variance in total biomass, var$(B_{i})$ behave?

    \item Simulation examples from Brad and Erin to illustrate.  FIA data analysis as well


\begin{slide}{Chave et al}

\item Chave et al. (Global Change Biology, 24 authors)

\item One ha plot with $500$ trees, all $\geq 10$ cms

\item Tree level CV $\approx .5$

\item $$\hat{CV}(B) \approx \hat{CV}(b(x)) \frac{\sqrt{\sum_{i} b^{2}(x_i)}}{\sum_{i} b(x_i)}$$

\item Claim: $\hat{CV}(B) \approx .05 - .1$

\item Again, $\sum_{i} b^{2}(x_i)$ is $O(N)$, $\sum_{i} b(x_i)$ is $O(N)$ so, simplistically, $CV(B)$ is $


\begin{slide}{A modeler's perspective}
\item  A natural way to model total biomass for a plot is to look at the collection of tree diameters on the plot as a
    marked point pattern of sizes.

    \item That is, the random number of trees and the sizes of the trees form a point pattern over the ``interval of sizes''
        say \textbf{X}.  Each tree has a mark or label indicating species type.

        \item The novelty is that we can not use a nonhomogeneous Poisson process (NHPP) model.  We do not have a notion of
            an intensity

            \item Rather, we have a generative model for a point pattern, ${\cal X}$, where ${\cal X} \equiv (N({\cal X})=n,
                x_1, x_2,..,x_n)$.  We generate the number of trees and then we generate the sizes (diameters) of the trees.



                \item So, $[{\cal X}] = [N({\cal X})=n, x_1, x_2,..,x_n] = [N({\cal X})=n][ x_1, x_2,..,x_n| N({\cal X})=n]$

\item We assume conditionally independent sizes so $[ x_1, x_2,..,x_n| N({\cal X})=n] = \Pi_{i=1}^{n} f_{n}(x_i)$

\item The crucial point is that the location density depends on $n$, i.e., a density dependent location distribution.

\item Reinforced by the earlier findings showing that the size distribution depends upon the number of individuals on the

    \item Not an NHPP where the location distribution us independent of $N$; no intensity $\gamma(x) = E(N({\cal X})) f(x)$.

        \item $N(A)$, the number of individuals in a size interval $A$ does \textbf{not} have a Poisson distribution



        \item In fact, we can calculate $P(N(A)=n) = \sum_{N=n}^{\infty} P(N(A) =n|N({\cal X}) = N)P(N({\cal X})=N) =
            \sum_{N=n}^{\infty} P(N(A)= n)P(N(A^{C} = N-n)P(N({\cal X})=N)  = \sum_{N=n}^{\infty} \left(
                                                                                                                N \\
                                                                                                                n \\
                                                                                                            X})=N) $

        \item In fact, we are suppressing $k$, the species label.  Really should have $N^{(k)}({\cal X})$ and  $N({\cal X})=
            \sum_{k}  N^{(k)}({\cal X})$

            \item Most importantly, we calculate total biomass $B$ as a function of the point pattern.  Again $B({\cal X})=
                \sum_{i} b(x_i)$.

                \item Distribution of $B({\cal X})$ is induced by model for ${\cal X}$. The distribution is not tractable
                    but can obtain expressions for the first and second moments (not simple forms)



                \item To calculate moments usually use Campbell's Thm which provides $E_{{\cal X}}\sum_{i} b(x_i)$ and
                    $E_{{\cal X}} \sum_{i,j} b(x_i)b(x_j)$ using the first and second moment measures.  However, not
                    applicable here due to $f_{N}(x)$.

                    \item Instead we use iterated expectation, e.g.,

                    $$E_{{\cal X}}B= E_{{\cal X}} \sum_{i} b(x_i) = E_{N} E_{x_1,x_2,...,x_N|N} \sum_{i} b(x_i)= E_{N} N E_{N}(b(x))$$

                    $$E_{{\cal X}}B^{2} = E_{{\cal X}} (\sum_{i} b(x_i))^{2} = E_{N} E_{x_1,x_2,...,x_N|N} (\sum_{i}

                    $$= E_{N} N \textit{var}_{N} b(x) + N^{2}(E_{N}b(x))^{2}$$

                    $$\textit{So,} \textit{var}_{{\cal X}} B = E_{N}[ N \textit{var}_{N}b(x) + \textit{var} (N E_{N} b(x))]$$



                    \item Here, $E_{N({\cal X})} b(x)$ is the tree level mean biomass, given $N({\cal X})$ from the density
                        dependent size distribution $f_{N({\cal X})}(x)$, etc.

                        \item With $K$ species we have $b_{k}(x)$ from the allometry for species $k$.  We have point
                            patterns, ${\cal X} = \{ {\cal X}^{(k)} \}$ with associated $\{N^{(k)}\}$ enabling $E_{{\cal
                            X}^{(k)}}B^{(k)}$ and $\textit{var}_{{\cal X}^{(k)}}B^{(k)}$ where we condition on $N=

                            \item Finally, we can obtain $E_{{\cal X}}(B) = \sum E_{{\cal X}^{(k)}}B^{(k)}$ and
                                $\textit{var}_{{\cal X}}(B) = \sum \textit{var}_{{\cal X}^{(k)}}B^{(k)}$


    \begin{slide}{Changing plot size/area}

    \item How does variation in biomass change with plot size? If unit area is ``1'', plot area $\ell$ consists of $\ell$
        unit areas

    \item This problem has a simple answer if the size distribution was not density dependent.  It will scale linearly in

        \item With density dependence no simple scaling is possible. No idea how to scale from FIA size plots to ha size

    \item Without density dependence, two perspectives: (i) total biomass through measurement error model, (ii) total
        biomass through counts and size classes

        \item Perspective (i) says $B^{(\ell)}_{i} = \eta_{\ell} + \epsilon^{(\ell)}_{i}$ where $\eta_{\ell}$ is mean
            biomass for a plot of area $\ell$.

            \item Then, independence of plots says $\textit{var}B^{(\ell)}_{i} = \ell \textit{var}B^{(1)}$, i.e., variance
                grows linearly in area.

                \item (Note that $B^{(\ell)} \neq \ell B^{(1)}$, i.e., variance is not $O(\ell^2)$.)

         %   \item What do we see in practice?


            \item Perspective (ii) says that for a plot of area $\ell$, we have a ``size intensity surface'',
                $\delta_{\ell}(x)$. Integrating $\delta_{\ell}(x)$ over $x$ yields mean number of individuals in a plot of
                area $\ell$

                \item Then, with allometric function $b(\cdot)$, expected biomass for the plot is $\eta_{\ell} = \int b(x)
                    \delta_{\ell}(x) dx$.
                    \item Now, suppose $N_{i} \sim Po(\delta_{\ell})$.  So, $E(N_{i}) = \textit{var}N_{i} = \delta_{\ell}$.

                    \item Want E$\sum_{j} b(x_{ij})$,  var$(\sum_{j} b(x_{ij}))$

                    \item Direct calculation of these quantities assuming point pattern of observed sizes is a
                        nonhomogeneous Poisson process with intensity $\delta_{\ell}(x)$ using  Campbell's Theorem.

                        \item Easier to discretize $\delta_{\ell}(x)$ to bins and replace the integral by a sum, counts in
                            bins having Poisson distributions.

                            \item If $ \delta_{\ell} = \ell \delta_{1}$, then, again variance grows linearly in area.

             %       \item Again, what do we see in practice?


                    \begin{slide}{Add allometry error}
                    \item Replace $b(x)$ with $b(x)\varepsilon(x)$ and $B= \sum_{i}b(x_i)\varepsilon(x_i)$ where
                        $\varepsilon(x) \sim$ lognormal.

                        \item Multiplicative error on biomass scale, additive normal error on log scale

                        \item Suggestions for variance of normal in the literature, by species

                        \item Can recalculate all of the foregoing
                        \item Provides a strategy for simulation of total biomass


                    \begin{slide}{A static model}


                    \item Write model as $B_{i} = \sum_{j=1}^{N_{i}} b(x_{ij}) \sim N(N_{i}\mu_{i}, \sigma^{2}_{i})$

                    \item $\mu_i$ depends upon $N_i$.  How?

                    \item $\sigma^{2}_{i}$ depends upon $N_{i}$.  How?

                    \item Essentially, a Central Limit Theorem approximation to replace earlier mean and variance
                        calculations arising from an inaccessible distribution for $B_i$ with an approximate normal

                        \item Variability in biomass at FIA plots will overwhelm covariate explanation

                        \item We would not model at individual tree level if we are interested in $\Delta$-biomass. Not the
                            same set of trees at two different time points - live, dead, recruits.


\begin{slide}{A dynamic model}

\item Again, with $E(B_{i}) = N_{i}\mu_{i}$, we need to model $\mu_{i}= E(b(x_{i}))$
\item  With dynamics, the key modeling idea:  to model $E(b(x_{it}))$ induced by a growth model for diameters, i.e., for
    $E(x_{it} - x_{i,t-1})$.

    \item A natural approach is to use a first order approximation, which, after taking expectations, becomes
 $$E(b(x_{it}) - b(x_{i,t-1})) \approx E(b^{'}(x_{it})(x_{it}-x_{i,t-1}))$$

  $$= E(b^{'}(x_{it}))E(x_{it}-x_{i,t-1})$$  if we assume independent increments.



 \item Two pieces on the right side. First, let's model
 $$E(x_{it}-x_{i,t-1}) = \beta_{0i} + \bbeta^{T}\mathbf{W}_{it}.$$
 \item A random walk with plot specific drift.  In particular, $\beta_{0i}$ provides the time dependent drift, i.e., the
     growth in plot $i$ due to aging of the plot and the other terms  provide the covariate-driven drift.

     \item We would define $\beta_{0i} = \beta_{0} + \tilde{\beta}_{0i}$ to give the ``global'' drift and the plot level
         random effect.

% The actual model for the diameters would look something like:
% $$D_{it} = D_{i,t-1} + \beta_{0i} + \beta_{1}TCI_{i} + \bbeta_{2}^{T}\mathbf{X}_{it} + \eta_{it}$$
% with the $\eta$'s being independent errors perhaps $\sim N(0, \sigma^{2}_{\eta})$.

\item  So, assembling, we have the recursion,
 $$\mu_{it}= \mu_{i,t-1} + E(b^{'}(x_{it}))(\beta_{0i} +

% I note that there does not seem to be any way to put autoregression into this since we really want to model differences,
% not autoregressive differences.  Perhaps we don't need it since we have a deterministic recursion for the $\gamma$ given
% the parameters and we  avoid explosive variance behavior for the $B_{it}$'s through our asymptotic variance assumption.



\item What is left is $E(b^{'}(x_{it}))$.  $b^{'}$ is known from the allometry, well behaved, differentiable and in fact,
    monotonic over  the positive diameters.  So, $E(b^{'}(D_{it}))>0$.

    \item But, expectation has no closed form so replace with a random effect.

    \item Write
$$\mu_{it} - \mu_{i,t-1} = \omega_{it}(\beta_{0i} +

\item $\omega_{it}$ plays the role of a positive scaling factor.  In order to identify it with regard to $\beta_{0i} +
    \bbeta^{T}\mathbf{W}_{it}$, we set its mean and variance to 1.

    \item Perhaps easiest to make them i.i.d. lognormal variables.

 %   , $z_{it} = \texttt{log}\omega_{it}$ where $z_{it} \sim N(-\frac{1}{2}\texttt{log}2, \texttt{log}2)$ (if my distribution
%        theory is correct). Of course any fixed values would identify them.  This choice enables interpretation in mean and
%        the uncertainty for the $\beta$'s.

\item Finally, we really need $\mu_{it} = \texttt{max}(0, \tilde{\mu}_{it})$.


\begin{slide}{Another dynamic modeling view}

\item Jim's view
\item A demographic approach, a point pattern approach, a plot level approach.

\item Envision a size intensity, $\gamma_{t}(x)$ evolving in time through an Integral Projection Model, i.e.,
    $\gamma_{t+1}(y) = \int_{\mathbf{X}} K_{t}(y;x) \gamma_{t}(x) dx$.  $K_{t}(y;x)$ introduces usual vital rates

    \item $\gamma_{t}(x)$ is reflective of the \emph{area} of the plot

    \item Also, carefully chosen density dependence for $\gamma_{t}(x)$.

    \item Then, expected total biomass at time $t$ becomes $\int_{\mathbf{X}} b(x) \gamma_{t}(x) dx$

    \item Again, can discretize to size bins.



Recommended reading 2021: •
LaTeX Beginner's Guide LaTeX Cookbook
User avatar
Site Moderator
Posts: 4183
Joined: Thu Nov 01, 2012 4:08 pm


Postby Johannes_B » Thu May 21, 2015 3:16 pm

Hi Alan, welcome to the forum.

I think the first step would be to calm down ;-)

When you fix the author block and run in dvi mode, do you get a succesful output? You cannot run in pdf-mode directly, prosper does not allow that.

If that does not work, please show us the log file of your attempt.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.

Posts: 3
Joined: Thu May 21, 2015 11:31 am


Postby Alan » Thu May 21, 2015 3:28 pm

Johannes - Thanks for the prompt reply and encouraging words. first, what do you mean by fix the author block. It was never a problem with my old version of WinEdt on my old Sony Vaio. Second, how can I run dvi. The only compile button available to me is either P or L. None of the others are lit. - Alan

User avatar
Site Moderator
Posts: 4183
Joined: Thu Nov 01, 2012 4:08 pm


Postby Johannes_B » Thu May 21, 2015 3:48 pm

The author command is commented, that means you will get an error for an undefined @Author.

I don't know WinEdt, to be honest. Have you considered compiling with a free and open source editor like Texworks?
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.

Posts: 3
Joined: Thu May 21, 2015 11:31 am


Postby Alan » Thu May 21, 2015 4:28 pm

I guess I paid good money for my version of WinEdt and I ought to be able to use it!

User avatar
Site Moderator
Posts: 4183
Joined: Thu Nov 01, 2012 4:08 pm


Postby Johannes_B » Thu May 21, 2015 8:51 pm

Alan wrote:I guess I paid good money for my version of WinEdt and I ought to be able to use it!

I can totally understand that :-) I chose to use free software for my TeX needs. Guess we have to wait for somebody actually working with WinEdt.

Since commercial software needs to keep customers happy, there is a support address you can use: WinEdt suppport.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.

Return to “WinEdt”

Who is online

Users browsing this forum: No registered users and 1 guest