Evoli: Popravki Klime kakovosti (ang in slo) oddelki in brez oddelkov

This commit is contained in:
Miha 2020-12-04 10:02:31 +01:00
parent 9fca43773a
commit df3de5b422
5 changed files with 16 additions and 61 deletions

View File

@ -72,13 +72,11 @@ if (data[1, 1] == ("Ustreznost") |
data <- subset(data, skupina == ID)
# Če oddelek nima podatka oziroma je manjkajoča vrednost,
# ga odstranimo v izogib errorju pri izdelavi frekvenčne tabele
data <- subset(data, oddelek_ime != -1)
#data <- subset(data, oddelek_ime != -1)
# Izberemo samo koncane ankete
data <- subset(data, status == 6)
#--------------------------- //IMPORT DATA// --------------------------#
# Preverimo ali oddelki obstajajo v nasprotnem bomo na to opozorili
if(nrow(data) > 0) {
# TEAMS / ODDELKI #
####################
@ -464,7 +462,7 @@ p <- ggplot(df, aes(x = factor(name))) +
# Rest of theme
coord_flip() +
scale_y_continuous(
position = "top",
position = "right",
# položaj osi je na vrgu grafa
expand = c(0, 0),
breaks = seq(min(0), max(0, 102), by = 10),
@ -498,7 +496,7 @@ p1 <- p + theme(axis.text.x = element_text(colour="black",size=11,face="plain"),
plot.title = element_text(hjust = 0.4,size = 15, face = "bold")) #+
#ggtitle("Employeeship for all teams")
p1 + theme(axis.ticks=element_blank())
print(p1 + theme(axis.ticks=element_blank()))
dev.off() # END: Save ggplot to pdf
# Shranimo sliko in vklju\u010Dimo v pdf: LATEX
@ -849,7 +847,7 @@ if (nrow(oddelek_length) > 0) {
# Rest of theme
coord_flip() +
scale_y_continuous(position = "top", # položaj osi je na vrgu grafa
scale_y_continuous(position = "right", # položaj osi je na vrgu grafa
expand = c(0, 0),
breaks = seq(min(0), max(0,102), by = 10),
limits = c(0,102),
@ -1002,28 +1000,8 @@ tex.izbor <- c(
drugi_del_tex,
"\\end{document}"
)
# Compile PDF
setwd(paste(Rdirektorij, "modules/mod_EVOLI/results", sep="/")) # File folder
cat(unlist(tex.izbor), file=paste0("Quality-climate.tex"), sep="\n") # Name of tex file
tools::texi2pdf(file=paste0("Quality-climate.tex"), quiet=TRUE, clean=TRUE) # Pdf file
setwd(Rdirektorij)
} else {
# Če ni oddelkov to napiši
Rdirektorij <- getwd() # Get working diretory
# Compiling file
tex.izbor <- c(
"\\documentclass{article}
\\begin{document}
Data for department (department name) is missing in the data. Please check!
\\end{document}"
)
setwd(paste(Rdirektorij, "modules/mod_EVOLI/results", sep="/")) # File folder
cat(unlist(tex.izbor), file=paste0("Quality-climate.tex"), sep="\n") # Name of tex file
tools::texi2pdf(file=paste0("Quality-climate.tex"), quiet=TRUE, clean=TRUE) # Pdf file
setwd(Rdirektorij)
}
setwd(Rdirektorij)

View File

@ -80,17 +80,15 @@ if (data[1, 1] == ("Ustreznost") |
data <- data[2:nrow(data),]
}
data <- subset(data, skupina == ID)
# Če oddelek nima podatka oziroma je manjkajoča vrednost,
# ga odstranimo v izogib errorju pri izdelavi frekvenčne tabele
data <- subset(data, oddelek_ime != -1)
#data <- subset(data, oddelek_ime != -1)
# Izberemo samo koncane ankete
data <- subset(data, status == 6)
#--------------------------- //IMPORT DATA// --------------------------#
# Preverimo ali oddelki obstajajo v nasprotnem bomo na to opozorili
if(nrow(data) > 0) {
# TEAMS / ODDELKI #
####################
# Skupine na podlagi katerih se bodo ra\u010Dunale vrednosti in izrisovale v grafih (glej SINTAX SPODAJ)
@ -477,7 +475,7 @@ p <- ggplot(df, aes(x = factor(name))) +
# Rest of theme
coord_flip() +
scale_y_continuous(
position = "top",
position = "right",
# položaj osi je na vrgu grafa
expand = c(0, 0),
breaks = seq(min(0), max(0, 102), by = 10),
@ -511,7 +509,7 @@ p1 <- p + theme(axis.text.x = element_text(colour="black",size=11,face="plain"),
plot.title = element_text(hjust = 0.4,size = 15, face = "bold")) #+
#ggtitle("Employeeship for all teams")
p1 + theme(axis.ticks=element_blank())
print(p1 + theme(axis.ticks=element_blank()))
dev.off() # END: Save ggplot to pdf
# Shranimo sliko in vklju\u010Dimo v pdf: LATEX
@ -862,7 +860,7 @@ if (nrow(oddelek_length) > 0) {
# Rest of theme
coord_flip() +
scale_y_continuous(position = "top", # položaj osi je na vrgu grafa
scale_y_continuous(position = "right", # položaj osi je na vrgu grafa
expand = c(0, 0),
breaks = seq(min(0), max(0,102), by = 10),
limits = c(0,102),
@ -947,7 +945,7 @@ customer <-
tex.glava <- scan("modules/mod_EVOLI/latexkosi/glava-evoli_klima_slo.tex", character(0), sep="\n", quiet=TRUE,encoding='UTF-8') # Define document (first page, ...)
tex.17.znakov <- scan("modules/mod_EVOLI/latexkosi/klima_17_znakov.tex", character(0), sep="\n", quiet=TRUE,encoding='UTF-8')
tex.glava <- gsub(pattern='!organisation!', replacement=Hmisc::latexTranslate(organisation), x=tex.glava) # Organisation name
tex.glava <- gsub(pattern='!date!', replacement=Hmisc::latexTranslate(date), x=tex.glava) # Organisation name
tex.glava <- gsub(pattern='!date!', replacement=Hmisc::latexTranslate(date[1]), x=tex.glava) # Organisation name
tex.glava <- gsub(pattern='COMPANY NAME', replacement=Hmisc::latexTranslate(organisation), x=tex.glava, fixed = TRUE) # Organisation name
tex.glava <- gsub(pattern='!name!', replacement=Hmisc::latexTranslate(customer), x=tex.glava, fixed = TRUE) # Customer name
tex.noga <- scan("modules/mod_EVOLI/latexkosi/z-noga.tex", character(0), sep="\n", quiet=TRUE) # End latex document
@ -967,29 +965,8 @@ tex.izbor <- c(
tex.17.znakov,
tex.noga
)
# Compile PDF
setwd(paste(Rdirektorij, "modules/mod_EVOLI/results", sep="/")) # File folder
cat(unlist(tex.izbor), file=paste0("Klima-kakovosti.tex"), sep="\n") # Name of tex file
tools::texi2pdf(file=paste0("Klima-kakovosti.tex"), quiet=TRUE, clean=TRUE) # Pdf file
setwd(Rdirektorij)
} else {
# Če ni oddelkov to napiši
Rdirektorij <- getwd() # Get working diretory
# Compiling file
tex.izbor <- c(
"\\documentclass{article}
\\begin{document}
V podatkih manjka podatek za oddelek (ime oddelka). Prosimo preverite!
\\end{document}"
)
setwd(paste(Rdirektorij, "modules/mod_EVOLI/results", sep="/")) # File folder
cat(unlist(tex.izbor), file=paste0("Quality-climate.tex"), sep="\n") # Name of tex file
tools::texi2pdf(file=paste0("Quality-climate.tex"), quiet=TRUE, clean=TRUE) # Pdf file
setwd(Rdirektorij)
}

View File

@ -398,7 +398,7 @@ of organisational systems and policies.
and online diagnostic tools to companies and organisations worldwide to enable them \\
to achieve long-lasting results at the personal, team and organisational levels. }
\end{center}
\\ \\
\ \\ \\
\begin{center}
{\small Claus M{\o}ller Consulting helps organisations to measure, improve and manage \\
productivity, relationships, quality, and leadership}.

View File

@ -734,7 +734,7 @@ samodisciplino".
\begin{center}
{\large \textbf{Kako uporabite orodje za posameznika}}
\end{center}
\\
\ \\
\renewcommand\labelitemi{\large$\bullet$}
\begin{itemize}
\item Vsak član tima mora pazljivo pregledati svoje lastne odgovore \\

View File

@ -674,7 +674,7 @@ strengthen your self-discipline''.
\begin{center}
{\large \textbf{How the individual can use the tool}}
\end{center}
\\
\ \\
\renewcommand\labelitemi{\large$\bullet$}
\begin{itemize}
\item Every employee should carefully study the \textit{Quality Climate} \\