publishBibliography

publishBibliography enables to create web page which contains the references inside the input .m files

Syntax

  • fstring=publishBibliography(InputCell,OUT)example
  • fstring=publishBibliography(InputCell,OUT,Name,Value)example
  • [fstring,citsCell]=publishBibliography(___)example

Description

This routine uses as input the cell which is created with routine makecontentsfileFS and the cell created by publishFSallFiles and uses template file bibliographyEmpty.html which is contained inside: (main root of FSDA) filesep 'helpfiles' filesep 'FSDA;

to create in a fully automatic way the bibliography file containing all the references.

The output file (if the path is not specified in input option outputDir) will be created inside: (main root of FSDA) filesep 'helpfiles' filesep 'FSDA;

and will have name bibliography.html

example

fstring =publishBibliography(InputCell, OUT) Skip_example publishBibliography with all the default options (and write2file false).

example

fstring =publishBibliography(InputCell, OUT, Name, Value) Example of use of option outputDir.

example

[fstring, citsCell] =publishBibliography(___) Example where second output is returned.

Examples

expand all

  • Skip_example publishBibliography with all the default options (and write2file false).
  • % Create the requested input arguments.
    FileName='addFSDA2path';
    FullPath=which(FileName);
    %Navigate to the main folder of FSDA
    FSDAroot=fileparts(FullPath);
    cd(FSDAroot)
    % Specify subfolders of main folders for which contents file has to be
    % created
    InclDir={'graphics' 'regression' 'multivariate' 'clustering' 'combinatorial' ...
    'examples' 'utilities' 'utilities_stat' 'utilities_help'};
    ExclDir={'privateFS'  'datasets'};
    % Create list of folders which must have the personalized contents file
    list = findDir(FSDAroot,'InclDir',InclDir,'ExclDir',ExclDir);
    % Crete personalized contents file for main folder of FSDA
    % and required subfolders.
    force=false;
    warning('off')
    [FilesIncluded,FilesExcluded]=makecontentsfileFS('dirpath',list,'FilterFileContent','%FScategory:','force',force,...
    'printOutputCell','Contents.m');
    [~,OUT]=publishFSallFiles(FilesIncluded, 'evalCode','false',...
    'write2file',false,'ErrWrngSeeAlso',false,'msg',false);
    warning('on')
    % Create HTML file containing all the items which make up the bibliography
    fileBiblio=publishBibliography(FilesIncluded,OUT,'write2file',false);

  • Example of use of option outputDir.
  • Create bibiography.html in the main root of FSDA.

    FileName='addFSDA2path';
    FullPath=which(FileName);
    %Navigate to the main folder of FSDA
    FSDAroot=fileparts(FullPath);
    cd(FSDAroot)
    % Specify file path where bibliography file has to be created.
    outputPath=pwd;
    % Specify subfolders of main folders for which contents file has to be
    % created
    InclDir={'graphics' 'regression' 'multivariate' 'clustering' 'combinatorial' ...
    'examples' 'utilities' 'utilities_stat' 'utilities_help'};
    ExclDir={'privateFS'  'datasets'};
    % Create list of folders which must have the personalized contents file
    list = findDir(FSDAroot,'InclDir',InclDir,'ExclDir',ExclDir);
    % Create personalized contents file for main folder of FSDA
    % and required subfolders.
    force=false;
    warning('off')
    [FilesIncluded,FilesExcluded]=makecontentsfileFS('dirpath',list,'FilterFileContent','%FScategory:','force',force,'printOutputCell','Contents.m');
    [~,OUT]=publishFSallFiles(FilesIncluded, 'evalCode','false','write2file',false,'ErrWrngSeeAlso',false,'msg',false);
    warning('on')
    % Finally create bibliography file and put its content inside variable fileBiblio
    fileBiblio=publishBibliography(FilesIncluded,OUT,'outputDir',outputPath,'write2file',true);

  • Example where second output is returned.
  • Skip_example In this case output Citations contains the list of the citations which have been found.

    FileName='addFSDA2path';
    FullPath=which(FileName);
    %Navigate to the main folder of FSDA
    FSDAroot=fileparts(FullPath);
    cd(FSDAroot)
    % Specify subfolders of main folders for which contents file has to be
    % created
    InclDir={'graphics' 'regression' 'multivariate' 'clustering' 'combinatorial' ...
    'examples' 'utilities' 'utilities_stat' 'utilities_help'};
    ExclDir={'privateFS'  'datasets'};
    % Create list of folders which must have the personalized contents file
    list = findDir(FSDAroot,'InclDir',InclDir,'ExclDir',ExclDir);
    % Create personalized contents file for main folder of FSDA
    % and required subfolders.
    force=false;
    warning('off')
    [FilesIncluded,FilesExcluded]=makecontentsfileFS('dirpath',list,'FilterFileContent','%FScategory:','force',force,'printOutputCell','Contents.m');
    [~,OUT]=publishFSallFiles(FilesIncluded, 'evalCode','false','write2file',false,'ErrWrngSeeAlso',false,'msg',false);
    warning('on')
    % Finally create bibliography file and put its content inside variable fileBiblio
    % output variable Citations shows where each refernce has been found.
    [fileBiblio,Citations]=publishBibliography(FilesIncluded,OUT,'write2file',false);
    %  disp(Citations)

    Input Arguments

    expand all

    InputCell — Cell created by function makecontentsfileFS.m. Cell.

    Cell containing the names of all files which have to be processed to produce the HTML file contanining the bibliography.

    Data Types: single| double

    OUT — Cell created by function publishFSallFiles.m. Cell.

    Cell of length size(InputCell,1). OUT{i} contains the output of the application of routine publishFS to i-th file, i=1, 2, ..., lengthInputCell.

    Data Types: single| double

    Name-Value Pair Arguments

    Specify optional comma-separated pairs of Name,Value arguments. Name is the argument name and Value is the corresponding value. Name must appear inside single quotes (' '). You can specify several name and value pair arguments in any order as Name1,Value1,...,NameN,ValueN.

    Example: 'webhelp',true , 'outputDir','C:' , 'write2file',false

    webhelp —Option which specifies the default path to create html file containing the categorical list of functions.logical.

    If webhelp is true, the output is produced in the path (FSDA root)\helpfiles\FSDAweb.

    If webhelp is false (default), the output is produced in the path (FSDA root)\helpfiles\FSDA.

    Note that this option is valid just if outpuDir option below is omitted.

    Example: 'webhelp',true

    Data Types: logical

    outputDir —Output folder.string.

    Output folder to which the HTML document is saved and where template file function-cateEmpty.html is located, specified as the comma-separated pair consisting of 'outputDir' and the full path. You must specify the full path as a string, for example 'C:\PublishedOutput'. Note that inside outputDir there must be a file named "function-cateEmpty.html" which contains the template to create the categorical list of functions. The defaults of 'outputDir' are as follows: if input option webhelp is false outputDir is (FSDA root)\helpfiles\FSDA path, else if input option webhelp is true outputDir is (FSDA root)\helpfiles\FSDAweb path.

    Remark - outputDir must be a valid path.

    Example: 'outputDir','C:'

    Data Types: string

    write2file —Option to write HTML file.logical.

    Option which specifies whether HTML file must be created or if just HTML string fstring must be created. The default value of write2file is true, that is html file is created

    Example: 'write2file',false

    Data Types: logical

    Output Arguments

    expand all

    fstring —HTML string with all the references. Character

    The HTML file bibliography.html is also produced inside folder specified by input option "outputDir" .

    citsCell —References, associated file and path. Cell

    Cell with three columns.

    First column = citation.

    Second column = FileName of associated file where citation was found.

    Third column = Path of associated file.

    More About

    expand all

    Additional Details

    Guidelines to create the references.


    [1] Example of book citation (note that the publisher town is not given and that the title of the book must be written in ""): Atkinson, A.C. and Riani, M. (2000), "Robust Diagnostic Regression Analysis", Springer Verlag.


    [2] Example of article citation (note that just the volume is given and that the name of the Journal is inside ""): Wong, C.K. and Easton, M.C. (1980), An Efficient Method for Weighted Sampling Without Replacement, "SIAM Journal of Computing", Vol. 9, pp. 111-113.


    [3] Example of InCollection (note that just the volume is given and that the name of the Journal is inside""): Riani, M., Cerioli, A., Atkinson, A.C., Perrotta, D. and Torti, F. (2008), Fitting Mixtures of Regression Lines with the Forward Search, in: "Mining Massive Data Sets for Security", Fogelman-Soulie F. et al. Eds., pp. 271-286, IOS Press.


    [4] IMPORTANT.

    Extra information which is attached to a citation inside the MATLAB .m file but does not have to appear in the output file bibliography.html must be inserted inside square parenthesis.

    For example in the citation below inside the .m file: Rousseeuw, P.J., Perrotta D., Riani M. and Hubert, M. (2018), Robust Monitoring of Many Time Series with Application to Fraud Detection, "Econometrics and Statistics". [quoted below as RPRH].

    The string [quoted below as RPRH] does not appear in the bibliography


    References

    This page has been automatically generated by our routine publishFS