I hope that you can help me to get customized labels for my bibliography.
I want to get a specific format for labels in bibliography, using \biblatex; only two characters, alphabetically ordered:
- The first character of the author's name.
- A number, which is the list for the first character.
I understood that I have to change the \DeclareLabelalphaTemplate; but I don't know how, I'm using this code:
\documentclass[11pt,a4paper]{article}
\usepackage[spanish, es-noshorthands]{babel}
\usepackage{csquotes}
\usepackage[backend=biber,style=alphabetic,backend=biber]{biblatex}
\usepackage{hyperref}
\addbibresource{bib.bib}
\DeclareLabelalphaTemplate{
\labelelement{
\field[final]{shorthand}
\field{label}
\field[strwidth=1,strside=left,ifnames=1,compound=false]{labelname}
}
\labelelement{ %I have to change or add here, I suppose.
\field[]{}
}
}
\begin{document}
These are my references, \cite{bael}, \cite{is}, \cite{macgregor}, \cite{morales}, \cite{nationalacademy-joints}, \cite{pfeiffer}.
\printbibliography
\end{document}
This is my bibliography data:
@book{morales,
author = {R. Morales},
title = {Diseño Estructural Sismorresistente},
publisher = {Fondo Editorial ICG},
year = {2002},
address = {Lima},
pages = {4-5},
}
@book{macgregor,
author = {J. MacGregor and J. Wight},
title = {Reinforced Concrete Mechanics and Design},
publisher = {Prentice Hall},
date = {2011},
location = {Upper Saddle River, New Jersey},
pages = {71-71},
}
@report{pfeiffer,
author = {Michael J. Pfeiffer, and David Darwin},
title = {Joint Design for Reinforced Concrete Buildings},
institution = {University of Kansas Structural Engineering and Materials Laboratory},
date = {1987},
location = {Lawrence, KS},
pages = {73},
}
@book{seae,
author = {Departamento de Tecnología Industrial},
title = {Código Técnico de la Edificación. Documento Básico SE-AE Seguridad Estructural: Acciones en la Edificación},
location = {Madrid},
date = {2007},
pages = {9},
}
@book{bael,
title = {Règles de techniques de conception et de calcul des ouvrages et construction en béton armé suivant la méthode des états limites},
author = {Ministère de l'Equipement des Transports et du Logement},
location = {Paris},
date = {1999},
pages = {86-87},
}
@book{is,
title = {Plain and Reinforced Concrete - Code of Practice IS 456-2000},
edition = {Fourth},
author = {Bureau of Indian Standards},
location = {Nueva Delhi},
date = {2000},
pages = {86-87},
}
@report{pca-joints,
title = {Buildings Movements and Joints},
author = {Portland Cement Association},
location = {Skokie, Illinois},
date = {1983},
pages = {36},
}
@report{nationalacademy-joints,
title = {Expansion Joints in Buildings},
author = {Standing Commitee on Structural Engineering of the Federal Construction Council},
number = {Technical Report No. 65},
institution = {National Academy of Sciences},
location = {Washington},
date = {1974},
pagetotal = {43},
}
@book{vallecilla,
author = {C. Ramiro Vallecilla},
title = {Fuerzas Sísmicas Principios y Aplicaciones NSR-98},
publisher = {Editorial Bauen},
location = {Bogotá},
date = {2003},
pages = {192-201},
}
@online{senhami,
author = {Servicion Nacional de Meteorología e Hidrología},
organization = {Ministerio del Ambiente},
title = {Datos Históricos},
url = {http://www.senamhi.gob.pe/main_mapa.php?t=dHi},
}
This image depicts, what I want,
