Description Usage Arguments Value Author(s) References Examples
View source: R/PlotShewhartCharts.R
The function plots the Shewhart charts for subgroups, in Phase I and Phase II.
1 | ShewhartSgpCharts(Data, PhaseIIData, ChartType, plot = TRUE)
|
Data |
Phase I partitioned subgroup summary (object type "Partition.SgpSummary") |
PhaseIIData |
Phase II subgroup summary (object type "SgpSummary") |
ChartType |
Chart type "Xbar"- Shewhart X-bar chart, "R"- Shewhart control chart for range, "S"- Shewhart S chart |
plot |
logical. If TRUE the corresponding Shewhart chart is plotted. |
plot Shewhart charts
Nadeeka Premarathna
Nadeeka Premarathna, A. Jonathan R. Godfrey and K. Govindaraju. "Decomposition of stock market trade-offs using Shewhart methodology." International Journal of Quality & Reliability Management 33, no. 9 (2016): 1311-1331.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | require(zoo)
SubgroupCriteria="weeks"
# data loading
data(AAPL)
#subgrouping Phase I data
StockPrice=window(AAPL[,"Close"],start=as.Date("2012-01-02"),end=as.Date("2013-12-31"))
Subgroups=Subgrouping(StockPrice,SubgroupCriteria,CountSgps=1)
# obtain subgroup summary of Phase I data
DataSum=SubgroupSummary(Subgroups,MaxSgpSize=5)
# partitioning data into common and special cause periods (Phase I data)
PartitonedData=PartitioningSgps(DataSum,ChartType="S")
# Phase II data
StockPrice=window(AAPL[,"Close"],start=as.Date("2014-01-06"),end=as.Date("2014-05-30"))
SubgroupsPhaseII=Subgrouping(StockPrice,SubgroupCriteria,CountSgps=1)
PhaseIIData=SubgroupSummary(SubgroupsPhaseII,MaxSgpSize=5)
B=ShewhartSgpCharts(PartitonedData, PhaseIIData,ChartType="S",plot=TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.