Shared posts
Asymmetry in Government Bond Returns
A Semiparametric Early Warning Model of Financial Stress Events
Alexander Didenkoиспользовать FSI как input в boosting для Меуччи
ECB projections as a tool for understanding policy decisions
Alexander Didenkomust read
The influence and policy signaling role of FOMC forecasts
Alexander Didenkomust read
Forecasting disaggregates by sectors and regions : the case of inflation in the euro area and Spain
Alexander Didenkoresearch ticket: "Are financial information flows spatially cointegrated? An evidence from emerging market IFCs"
Overcoming the difficulties of developing and transferring an input-output model for electricity consumption forecasts to the users
A New Graphical Tool for Copula Selection
Automatic declustering of rare events
The analysis of events with low probability but disastrous impact entails understanding how they cluster in time. We present an automatic three-step procedure for identifying clusters, estimating the cluster size distribution and constructing confidence intervals for the extremal index, which measures the degree of clustering of rare events. The third step combines empirical likelihood and parametric likelihood approaches. Simulations show that our new procedure performs very well for finite samples and outperforms previous methods in constructing confidence intervals for the extremal index when there is clustering in the data, as well as in estimating probabilities for small clusters.
SMOOTH DYNAMIC FACTOR ANALYSIS WITH APPLICATION TO THE US TERM STRUCTURE OF INTEREST RATES
Alexander Didenkomust read
SUMMARY
We consider the dynamic factor model and show how smoothness restrictions can be imposed on factor loadings by using cubic spline functions. We develop statistical procedures based on Wald, Lagrange multiplier and likelihood ratio tests for this purpose. The methodology is illustrated by analyzing a newly updated monthly time series panel of US term structure of interest rates. Dynamic factor models with and without smooth loadings are compared with dynamic models based on Nelson–Siegel and cubic spline yield curves. We conclude that smoothness restrictions on factor loadings are supported by the interest rate data and can lead to more accurate forecasts. Copyright © 2013 John Wiley & Sons, Ltd.
How to Select Representative Samples
ABSTRACT
We give a formal definition of a representative sample, but roughly speaking, it is a scaled-down version of the population, capturing its characteristics. New methods for selecting representative probability samples in the presence of auxiliary variables are introduced. Representative samples are needed for multipurpose surveys, when several target variables are of interest. Such samples also enable estimation of parameters in subspaces and improved estimation of target variable distributions. We describe how two recently proposed sampling designs can be used to produce representative samples. Both designs use distance between population units when producing a sample. We propose a distance function that can calculate distances between units in general auxiliary spaces. We also propose a variance estimator for the commonly used Horvitz–Thompson estimator. Real data as well as illustrative examples show that representative samples are obtained and that the variance of the Horvitz–Thompson estimator is reduced compared with simple random sampling.
Locality statistics for anomaly detection in time series of graphs. (arXiv:1306.0267v1 [stat.AP])
The ability to detect change-points in a dynamic network or a time series of graphs is an increasingly important task in many applications of the emerging discipline of graph signal processing. This paper formulates change-point detection as a hypothesis testing problem in terms of a generative latent position model, focusing on the special case of the Stochastic Block Model time series. We analyze two classes of scan statistics, based on distinct underlying locality statistics presented in the literature. Our main contribution is the derivation of the limiting distributions and power characteristics of the competing scan statistics. Performance is compared theoretically, on synthetic data, and on the Enron email corpus. We demonstrate that both statistics are admissible in one simple setting, while one of the statistics is inadmissible a second setting.
Wormhole Hamiltonian Monte Carlo. (arXiv:1306.0063v1 [stat.CO])
We propose a new Markov Chain Monte Carlo algorithm for sampling from multimodal distributions, especially when the dimension is high and the modes are isolated. Our method exploits and modifies the Riemannian geometric properties of the target distribution to create wormholes connecting modes in order to facilitate moving between them.
Online Tracking of a Drifting Parameter of a Time Series. (arXiv:1306.0325v1 [math.ST])
We propose an online algorithm for tracking a multivariate time-varying parameter of a time series. The algorithm is driven by a gain function. Under assumptions on the gain function, we derive uniform error bounds on the tracking algorithm in terms of chosen step size for the algorithm and on the variation of the parameter of interest. We give examples of a number of different variational setups for the parameter where our result can be applied, and we also outline how appropriate gain functions can be constructed. We treat in some detail the tracking of time varying parameters of an AR($d$) model as a particular application of our method.
A Gang of Bandits. (arXiv:1306.0811v1 [cs.LG])
Multi-armed bandit problems are receiving a great deal of attention because they adequately formalize the exploration-exploitation trade-offs arising in several industrially relevant applications, such as online advertisement and, more generally, recommendation systems. In many cases, however, these applications have a strong social component, whose integration in the bandit algorithm could lead to a dramatic performance increase. For instance, we may want to serve content to a group of users by taking advantage of an underlying network of social relationships among them. In this paper, we introduce novel algorithmic approaches to the solution of such networked bandit problems. More specifically, we design and analyze a global strategy which allocates a bandit algorithm to each network node (user) and allows it to "share" signals (contexts and payoffs) with the neghboring nodes. We then derive two more scalable variants of this strategy based on different ways of clustering the graph nodes. We experimentally compare the algorithm and its variants to state-of-the-art methods for contextual bandits that do not use the relational information. Our experiments, carried out on synthetic and real-world datasets, show a marked increase in prediction performance obtained by exploiting the network structure.
Agent-based multi-optional model of innovations diffusion. (arXiv:1306.1110v1 [stat.AP])
We propose a formalism that allows the study of the process of diffusion of several products competing in a common market. It is based on the generalization of the statistics Ising model (Potts model). For the implementation, agent based modeling is used, applied to a problem of three options; to adopt a product A, a product B, or non-adoption. A launching strategy is analyzed for one of the two products, which delays its launching with the objective of competing with improvements. The proportion reached by one and another product is calculated at market saturation. The simulations are produced varying the social network topology, the uncertainty in the decision, and the population's homogeneity.
The Dirichlet Portfolio Model: Uncovering the Hidden Composition of Hedge Fund Investments. (arXiv:1306.0938v1 [stat.AP])
Alexander Didenkomust read
Hedge funds have long been viewed as a veritable "black box" of investing since outsiders may never view the exact composition of portfolio holdings. Therefore, the ability to estimate an informative set of asset weights is highly desirable for analysis. We present a compositional state space model for estimation of an investment portfolio's unobserved asset allocation weightings on a set of candidate assets when the only observed information is the time series of portfolio returns and the candidate asset returns. In this paper, we exhibit both sequential Monte Carlo numerical and conditionally Normal analytical approaches to solve for estimates of the unobserved asset weight time series. This methodology is motivated by the estimation of monthly asset class weights on the aggregate hedge fund industry from 1996 to 2012. Furthermore, we show how to implement the results as predictive investment weightings in order to construct hedge fund replicating portfolios.
(More) Efficient Reinforcement Learning via Posterior Sampling. (arXiv:1306.0940v1 [stat.ML])
Alexander DidenkoМеуччи
Most provably-efficient learning algorithms introduce optimism about poorly-understood states and actions to encourage exploration. We study an alternative approach for efficient exploration, \emph{posterior sampling for reinforcement learning} (PSRL). This algorithm proceeds in repeated episodes of known duration. At the start of each episode, PSRL updates a prior distribution over Markov decision processes and takes one sample from this posterior. PSRL then follows the policy that is optimal for this sample during the episode. The algorithm is conceptually simple, computationally efficient and allows an agent to encode prior knowledge in a natural way. We establish an $\tilde{O}(\tau S \sqrt{AT})$ bound on the expected regret, where $T$ is time, $\tau$ is the episode length and $S$ and $A$ are the cardinalities of the state and action spaces. This bound is one of the first for an algorithm not based on optimism, and close to the state of the art for any reinforcement learning algorithm. We show through simulation that PSRL significantly outperforms existing algorithms with similar regret bounds.
Valid post-selection inference. (arXiv:1306.1059v1 [math.ST])
It is common practice in statistical data analysis to perform data-driven variable selection and derive statistical inference from the resulting model. Such inference enjoys none of the guarantees that classical statistical theory provides for tests and confidence intervals when the model has been chosen a priori. We propose to produce valid ``post-selection inference'' by reducing the problem to one of simultaneous inference and hence suitably widening conventional confidence and retention intervals. Simultaneity is required for all linear functions that arise as coefficient estimates in all submodels. By purchasing ``simultaneity insurance'' for all possible submodels, the resulting post-selection inference is rendered universally valid under all possible model selection procedures. This inference is therefore generally conservative for particular selection procedures, but it is always less conservative than full Scheffe protection. Importantly it does not depend on the truth of the selected submodel, and hence it produces valid inference even in wrong models. We describe the structure of the simultaneous inference problem and give some asymptotic results.
Inferring Robot Task Plans from Human Team Meetings: A Generative Modeling Approach with Logic-Based Prior. (arXiv:1306.0963v1 [cs.AI])
Alexander Didenkoзаседание investment committee
We aim to reduce the burden of programming and deploying autonomous systems to work in concert with people in time-critical domains, such as military field operations and disaster response. Deployment plans for these operations are frequently negotiated on-the-fly by teams of human planners. A human operator then translates the agreed upon plan into machine instructions for the robots. We present an algorithm that reduces this translation burden by inferring the final plan from a processed form of the human team's planning conversation. Our approach combines probabilistic generative modeling with logical plan validation used to compute a highly structured prior over possible plans. This hybrid approach enables us to overcome the challenge of performing inference over the large solution space with only a small amount of noisy data from the team planning session. We validate the algorithm through human subject experimentation and show we are able to infer a human team's final plan with 83% accuracy on average. We also describe a robot demonstration in which two people plan and execute a first-response collaborative task with a PR2 robot. To the best of our knowledge, this is the first work that integrates a logical planning technique within a generative model to perform plan inference.
Box-plot with R – Tutorial
Stat11 |
Stat21 |
Stat31 |
Stat41 |
Stat12 |
Stat22 |
Stat32 |
Stat42 |
Stat13 |
Stat23 |
Stat33 |
Stat43 |
5 |
2 |
9 |
-3 |
10 |
4 |
1 |
1 |
4 |
1 |
5 |
9 |
6 |
13 |
8 |
3 |
7 |
3 |
10 |
10 |
10 |
5 |
9 |
8 |
4 |
4 |
6 |
0 |
10 |
6 |
7 |
6 |
6 |
8 |
2 |
7 |
6 |
7 |
6 |
3 |
9 |
1 |
7 |
0 |
1 |
0 |
6 |
0 |
0 |
2 |
8 |
1 |
6 |
8 |
0 |
8 |
3 |
10 |
9 |
8 |
0 |
19 |
10 |
0 |
11 |
10 |
5 |
6 |
5 |
8 |
10 |
1 |
7 |
4 |
5 |
-5 |
7 |
0 |
3 |
5 |
2 |
5 |
5 |
3 |
4 |
12 |
9 |
-4 |
7 |
1 |
9 |
0 |
7 |
2 |
1 |
7 |
7 |
3 |
9 |
0 |
11 |
0 |
8 |
1 |
7 |
0 |
7 |
7 |
6 |
19 |
8 |
3 |
10 |
10 |
9 |
6 |
0 |
2 |
8 |
2 |
6 |
13 |
6 |
-5 |
12 |
8 |
1 |
4 |
0 |
4 |
5 |
10 |
8 |
11 |
6 |
-1 |
11 |
4 |
4 |
1 |
4 |
6 |
6 |
10 |
8 |
13 |
5 |
-5 |
7 |
10 |
0 |
4 |
2 |
7 |
3 |
1 |
2 |
8 |
5 |
-2 |
5 |
7 |
4 |
2 |
7 |
0 |
3 |
1 |
8 |
11 |
7 |
3 |
11 |
1 |
0 |
9 |
2 |
3 |
5 |
8 |
4 |
19 |
5 |
-1 |
11 |
6 |
3 |
4 |
9 |
5 |
9 |
0 |
2 |
9 |
5 |
-3 |
12 |
7 |
6 |
4 |
8 |
2 |
6 |
8 |
7 |
10 |
5 |
-4 |
8 |
9 |
6 |
9 |
1 |
4 |
3 |
4 |
… |
… |
… |
… |
… |
… |
… |
… |
… |
… |
… |
… |
R-bloggers.com offers daily e-mail updates about R news and tutorials on topics such as: visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...
Feature Selection 3 – Swarm Mentality
Alexander Didenkoиспользовать для оптимизации портфеля, в Меуччи - для генерации views, при оптимизации TTR
"Bees don't swarm in a mango grove for nothing. Where can you see a wisp of smoke without a fire?" - Hla Stavhana
In the last two posts, genetic algorithms were used as feature wrappers to search for more effective subsets of predictors. Here, I will do the same with another type of search algorithm: particle swarm optimization.
Like genetic algorithms, this search procedure is motivated by a natural phenomenon, such as the movements of bird flocks. An excellent reference for this technique is Poli et al (2007). The methodology was originally developed for optimizing real valued parameters, but was later adapted for discrete optimization by Kennedy and Eberhart (1997).
The optimization is initiated with configurations (i.e. multiple particles). In our case, the particles will be different predictor subsets. For now, let's stick with the parameters being real-valued variables. A particular value of a particle is taken to be it's position. In addition to a position, each particle has an associated velocity. For the first iteration, these are based on random numbers.
Each particle produces a fitness value. As with genetic algorithms, this is some measure of model fit. The next candidate set of predictors that a particle evaluates is based on it's last position and it's current velocity.
A swarm of particle are evaluated at once and the location of the best particle is determined. As the velocity of each particle is updated, the update is a function of the:
- previous velocity,
- last position and
- the position of the best particle
There are other parameters of the search procedure, such as the number of particles or how much relative weight the positions of the individual and best particle are used to determine the next candidate point, but this is the basic algorithm in a nutshell.
As an example, consider optimzing the Rosenbrock function with two real-valued variables (A and B):
fitness = 100*(B - A^2)^2 + (A - 1)^2
The best value is at (A = 1, B = 1). The movie below shows a particle swarm optimization using 100 iterations. The predicted best (solid white dot) is consistently in the neighborhood of the optimum value at around 50 iterations. You may need to refresh your browser to re-start the animation.

When searching for subsets, the quantities that we search over are binary (i.e. the predictor is used or excluded from the model). The description above implies that the position is a real valued quantity. If the positions are centered around zero, Kennedy and Eberhart (1997) suggested using a sigmoidal function to translate this value be between zero and one. A uniform random number is used to determine the binary version of the position that is evaluated. Other strategies have been proposed, including the application of a simple threshold to the translated position (i.e. if the translated position is above 0.5, include the predictor).
R has the pso package that implements this algorithm. It does not work for discrete optimization that we need for feature selection. Since its licensed under the GPL, I took the code and removed the parts specific to real valued optimization. That code is linked that the bottom of the page. I structured it to be similar to the R code for genetic algorithms. One input into the modified pso function is a list that has modules for fitting the model, generating predictions, evaluating the fitness function and so on. I've made some changes so that each particle can return multiple values and will treat the first as the fitness function. I'll fit the same QDA model as before to the same simulated data set. First, here are the QDA functions:
qda_pso 0)
{
mod 0)
{
testROC Here is the familiar code to generate the simulated data:
set.seed(468)
training To run the optimization, the code will be similar to the GA code used in the last two posts:
set.seed(235)
psoModel Since this is simulated data, we can evaluate how well the search went using estimates of the fitness (the area under the ROC curve) calculated using different data sets: resampling, a test set of 500 samples and large set of 10,000 samples that we use to approximate the truth.
The swarm did not consistently move to smaller subsets and, as with the original GA, it overfits to the predictors. This is demonstrated by the increase in the resampled fitness estimates and mediocre test/large sample estimates:

One tactic that helped the GA was to bias the algorithm towards smaller subsets. For PSO, this can be accomplished during the conversion from real valued positions to binary encodings. The previous code used a value of 1 for a predictor if the "squashed" version (i.e. after applying a sigmoidal function) was greater than 0.5. We can bias the subsets by increasing the threshold. This should start the process with smaller subsets and, since we raise the criteria for activating a predictor, only increase the subset size if there is a considerable increase in the fitness function. Here is the code for that conversion and another run of the PSO:
smallerSubsets = .7, 1, 0)
## 'x' has particles in columns and predicors in rows,
## so use apply() to threshold the positions
apply(binary, 2, function(x) which(x == 1))
}
set.seed(235)
psoSmallModel The results are much better:

The large-sample and test set fitness values agree with the resampled versions. A smoothed version of the number of predictors over iterations shows that the search is driving down the number of predictors and keeping them low:

And here are the large-sample ROC curves so far:

For the simulated data, the GA and PSO procedures effectively reduced the number of predictors. After reading the last few posts, one could easily remark that I was only able to do this since I knew what the answers should be. If the optimal subset size was not small, would these approaches have been effective? The next (and final) post in this series will apply these methods to a real data set.
The code for these analyses are here and the modified PSO code is here. Thanks to Claus Bendtsen for the original pso code and for answering my email.
To leave a comment for the author, please follow the link and comment on his blog: Blog - Applied Predictive Modeling.
R-bloggers.com offers daily e-mail updates about R news and tutorials on topics such as: visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...
The First Number You Should Look for When Choosing a Mutual Fund
IPO at LSE
Alexander Didenko6 июня. Нужно идти
View: Retail sales
Alexander DidenkoФолловеры из Алго: добавьте этот фид себе пожалуйста. Они нам нужны









