Title: | General Analysis of Various Economics Demand Systems |
Version: | 1.0 |
Imports: | stats, graphics |
Description: | Tools for general properties including price, quantity, elasticity, convexity, marginal revenue and manifold of various economics demand systems including Linear, Translog, CES, LES and CREMR. |
Depends: | R (≥ 3.2.2) |
License: | GNU General Public License version 2 |
Encoding: | UTF-8 |
LazyData: | true |
RoxygenNote: | 5.0.1 |
NeedsCompilation: | no |
Packaged: | 2016-07-15 18:13:29 UTC; tianhaowu |
Author: | Tianhao Wu [aut, cre] |
Maintainer: | Tianhao Wu <tianhao.wu@yale.edu> |
Repository: | CRAN |
Date/Publication: | 2016-07-16 00:01:13 |
Price and General Propeties Given Quantity
Description
Finds the prices and returns general propeties when quantities are given of various economics demand systems including Linear, Translog, CES, LES and CREMR.
Usage
DemandPrice(q, parameter, method, Plot, message)
Arguments
q |
the quantity vector |
parameter |
the parameters of the economics demand system. When choosing CREMR demand, it should be three dimensional, otherwise it should be two dimensional. |
method |
the demand function used, can be one of Linear, Translog, CES, LES and CREMR |
Plot |
a logical value indicating whether the manifold should be plotted |
message |
a logical value indicating whether an important message about the computed quantity should be printed |
Value
price |
the computed price |
sales |
the total sales (revenues) |
elasticity |
the elasticity of demand |
convexity |
the convexity of demand |
marginal.revenue |
the marginal revenues |
Examples
#Set quantity vector
quantity<-c(1,1.1,1.2)
#Use Translog Demand Function
X<-DemandPrice(quantity, c(10,0.5), "Translog", Plot=TRUE, message=TRUE)
#Return the prices
X$price
#Return the demand elasticity
X$elasticity
Quantity and General Propeties Given Price
Description
Finds the quantities (outputs) and returns general propeties when prices are given of various economics demand systems including Linear, Translog, CES, LES and CREMR.
Usage
DemandQuantity(p, parameter, method, Plot, message)
Arguments
p |
the price vector |
parameter |
the parameters of the economics demand system. When choosing CREMR demand, it should be three dimensional, otherwise it should be two dimensional. |
method |
the demand function used, can be one of Linear, Translog, CES, LES and CREMR |
Plot |
a logical value indicating whether the manifold should be plotted |
message |
a logical value indicating whether an important message about the computed quantity should be printed |
Value
quantity |
the computed quantity |
sales |
the total sales (revenues) |
elasticity |
the elasticity of demand |
convexity |
the convexity of demand |
marginal.revenue |
the marginal revenues |
Examples
#Set price vector
price<-c(1,1.1,1.2)
#Use Linear Demand Function
X<-DemandQuantity(price,c(10,0.5), "Linear", Plot=TRUE, message=TRUE)
#Return the quantities
X$quantity
#Return the marginal revenues
X$marginal.revenue