Description Usage Arguments Value Author(s) References Examples
View source: R/TargetDiagram.R
In a PV plant, the individual systems are theoretically identical and their performance along the time should be the same. Due to their practical differences –power tolerance, dispersion losses, dust–, the individual performance of each system will deviate from the average behaviour. However, when a system is performing correctly, these deviations are constrained inside a range and should not be regarded as sign of malfunctioning.
If these common deviations are assumed as a random process, a statistical analysis of the performance of the whole set of systems can identify a faulty system as the one that departs significantly from the mean behaviour.
These functions compare the daily performance of each system with a reference (for example, the median of the whole set) during a time period of N days preceding the current day. They calculate a set of statistics of the performance of the PV plant as a whole, and another set of the comparison with the reference. This statistical analysis can be summarised with a graphical tool named "Target Diagram", which plots together the root mean square difference, the average difference and the standard deviation of the difference. Besides, this diagram includes the sign of the difference of the standard deviations of the system and the reference.
1 2 | analyzeData(x, ref=NULL)
TargetDiagram(x, end, ndays, ref=NULL, color=NULL, cex=0.8,...)
|
x |
A |
ref |
A |
end |
A |
ndays |
A numeric vector, where each element is the number of days to be included in each analysis. |
color |
If |
cex |
Size of the labels. |
... |
Arguments to be read by |
The result of TargetDiagram
is a list
with two
components:
a trellis
object with the plot.
a zoo
object with err
component of the result of
analyzeData
.
The result of analyzeData
is a list
with two
components:
a zoo
object with the time evolution of several
statistics (mean, median, standard deviation, median absolute
deviation and interquantile range) of the set as a whole.
a data.frame
with the same number of rows as the
number of columns of the x
object. It contains several columns
with the statistics of the diference between each unit and the
reference (see the references for details.)
Oscar Perpiñán Lamigueiro.
Jolliff, J.; Kindle, J. C.; Shulman, I.; Penta, B.; Friedrichs, M. A. M.; Helber, R. & Arnone, R. A. Summary diagrams for coupled hydrodynamic-ecosystem model skill assessment Journal of Marine Systems, 2009, 76, 64-82.
O. Perpiñán, Statistical analysis of the performance and simulation of a two-axis tracking PV system, Solar Energy, 83:11(2074–2085), 2009.http://oa.upm.es/1843/1/PERPINAN_ART2009_01.pdf
Taylor, K. E. Summarizing multiple aspects of model performance in a single diagram, Program for Climate Model Diagnosis and Intercomparison, 2000, http://www-pcmdi.llnl.gov/publications/pdf/55.pdf
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | library(lattice)
library(latticeExtra)
data(prodEx)
prodStat<-analyzeData(prodEx)
xyplot(prodStat$stat)
dif<-prodEx-prodStat$stat$Median;
day=as.Date('2008-8-29')
horizonplot(window(dif, start=day-90, end=day),
origin=0, layout=c(1, 22), colorkey=TRUE, colorkey.digits=1,
scales=list(y=list(relation="same")))
###With a external reference
ref1=apply(prodEx, 1, median, na.rm=1)
prodStat1=analyzeData(prodEx, ref=ref1)
identical(prodStat, prodStat1)
###Target Diagram
ndays=c(5, 10, 15, 20)
#Color
if (require(RColorBrewer)){
palette=brewer.pal(n=length(ndays), name='Set1')
TDColor<-TargetDiagram(prodEx, end=day, ndays=ndays,
color=palette)
}
#B&W
TDbw<-TargetDiagram(prodEx, end=day, ndays=ndays)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.