Suppose to have a dataset containing feature vectors representing some people. Each feature vector contains mixed type of attributes (e.g. sex, age, height, hair color, favourite film, ...).  For example, these could be some instances:      ["Male", 28, 1.72, "brown", "star wars rebels", ...],     ["Female", 33, 1.65, "blonde", "seven pounds", ...],     ["Female", 19, 1.60, "blonde", "star trek", ...],     ["Male", 37, 1.84, "black", "star wars return of the jedi", ...],     ...   I want to cluster these people to find groups of similar people. There are several type of attributes. In particular, the sex is a binary attribute, the age is a discrete value, the height is a continuous value, the hair color is a categorical (aka nominal) attribute (i.e. has a finite set of values), but the last attribute is a string with infinite values. I found nothing in letterature about string values.  I'm not looking for a particular algorithm, because I'm interested to experiment with several algorithms and not only one. A large part of the clustering algorithms work only with numeric attributes. In this case, categorical attributes can be a problem, but there are some methods to represent them in a numeric form (e.g. 1-of-n, aka one-hot encoding). The real issue is that I can't understand how to handle the string attributes, obviously I can't use the 1-of-n technique. I tried to search, but I didn't find anything.  Maybe an approach could be to use a certain hash function to "convert" the strings into numbers? I think this solution could lead to a wrong clustering (depending also from the hash function)
I wonder whether it is possible to perform within R a clustering of data having mixed data variables. In other words I have a data set containing both numerical and categorical variables within and I'm finding the best way to cluster them. In SPSS I would use two - step cluster. I wonder whether in R can I find a similar techniques. I was told about poLCA package, but I'm not sure ...
Why is it better to use "#!/usr/bin/env NAME" instead of "#!/path/to/NAME" as my shebang? Proving $2$ generates $(\mathbb{Z}/19\mathbb{Z})^*$ by only looking at a few powers \section*[toc]{normal section title} not working for me We have duplicates in our all contacts in Marketing Cloud. To solve this, we want to delete all contacts (audience builder).   We use the Marketing Cloud connector, and send emails to synchronized data extensions. Because of this connector the all contacts will be filled with fresh data after 15 minutes right?  Is there any reason not to do this? What can go wrong? List of Figures + Beamer? I want to have a List of Figures in my Beamer presentation.  I spent some time searching the web for a solution and only found desperate people telling others that it's not possible, i.e.  or .  I also made some experiments on my own, i.e. "abuse" tocloft to do the job. However, even \usepackage{tocloft} causes pdflatex to fail with ! LaTeX Error: \l@section undefined. (and lying to tocloft by defining the command as empty beforehand doesn't to any good either).  I can't really see why it should be that difficult to make a List of Figures in beamer, since \tableofcontents works flawlessly.   I'm not afraid of doing some coding on my own, but I'm not deep enough into TeX to really understand the magic behind the "List of Figures", "Table of Contents" and alike.  Is anyone out there having suggestions or links that might help me figure this out?  \documentclass{beamer}  % uncomment the following line % to get the error message % `! LaTeX Error: \l@section undefined.`  %\usepackage{tocloft}   % uncomment the following lines INSTEAD % to lie to tocloft % and get the next error message  %\makeatletter %\newcommand\l@section{} %\makeatother %\usepackage{tocloft}  \begin{document}  \begin{frame}{A frame} \begin{figure} \mbox{A} \caption{An 'A'} \end{figure} \end{frame}  \begin{frame}{List of Figures} \listoffigures \end{frame}  \end{document}   EDIT: Solution  Starting from Marco Daniels answer to my question, I modified his code to reflect my needs. Here is what I came up with. Please feel free to comment, improve and reuse this.  \RequirePackage{ifthen}  \makeatletter  \AtEndDocument{%   \clearpage   \beamer@tempcount=\c@page\advance\beamer@tempcount by -1%   \if@filesw   \newwrite\tf@lof   \immediate\openout\tf@lof\jobname.lof\relax   \newwrite\tf@lot   \immediate\openout\tf@lot\jobname.lot\relax   \fi }  \long\def\beamer@makecaption#1#2#3#4{%   \def\insertcaptionname{\csname#1name\endcsname}%   \def\insertcaptionnumber{\csname the#1\endcsname}%   \edef\insertframenumber{\theframenumber}%   \ifthenelse{\equal{#3}{\empty}}{%       \def\insertlistcaption{#2}%   }{%     \def\insertlistcaption{#3}%   }   \def\insertsource{#4}%   \def\insertcaption{#2}%   \ifthenelse{\equal{#1}{figure}}{%       \addtocontents{lof}{\protect\listoffigureformat{\insertcaptionnumber}{\insertlistcaption}{\insertframenumber}{\insertsource}}{}{}%   }{}   \ifthenelse{\equal{#1}{table}}{%       \addtocontents{lot}{\protect\listoftableformat{\insertcaptionnumber}{\insertlistcaption}{\insertframenumber}}{}{}%   }{}   \nobreak\vskip\abovecaptionskip\nobreak   \sbox\@tempboxa{\usebeamertemplate**{caption}}%   \ifdim \wd\@tempboxa &gt;\hsize   \usebeamertemplate**{caption}\par   \else   \global \@minipagefalse   \hb@xt@\hsize{\hfil\box\@tempboxa\hfil}%   \fi   \nobreak\vskip\belowcaptionskip\nobreak% }  \def\listoffigureformat#1#2#3#4{%   \makebox[2ex][r]{#1}%   \hspace{1ex}%   {\usebeamercolor[fg]{bibliography entry author} #2}%   \ifthenelse{\equal{#4}{\empty}}{}{ -- #4}%   \dotfill%   \makebox[2ex][r]{#3}\par% } \def\listoffigures{%   \setlength{\leftskip}{3ex}   \setlength{\parindent}{-3ex}   \@starttoc{lof}% } \def\listoftableformat#1#2#3{\makebox[2ex][r]{#1}\hspace{1ex}#2\dotfill\makebox[2ex][r]{#3}\par} \def\listoftables{%   \setlength{\leftskip}{3ex}   \setlength{\parindent}{-3ex}   \@starttoc{lot}% }  \long\def\@caption#1[#2]#3{   \par\nobreak   \begingroup     \@parboxrestore     \if@minipage       \@setminipage     \fi     \beamer@makecaption{#1}{\ignorespaces #3}{\ignorespaces #3}{\ignorespaces #2}\par\nobreak     \endgroup}  \makeatother Reinstall Windows 8 on a Windows 8 based system with embedded key I'm a computer technician and we started selling few Windows 8 machine. We saw the new COA label does not show the key and after reading a little bit online, realized those systems came with the key emmebeded in the eUFI BIOS.   My question is : How do I reinstall Windows 8 if the hard drive is crashed? I kind of get that you can install it with a media and the media should activate the licence embedded. What is the media required? Is a retail DVD is able to do the work or do I need a system builder kit? I understand the manufacturer is reponsible to provide media  or replace the failed drive under the warranty but what will happen when warranty expire? I'll have to sell a full windows 8 licence with a key?  Thanks Direct Link to a Comment I'm doing some exercises on Apostol's calculus, on the floor function. Now, he doesn't give an explicit definition of $[x]$, so I'm going with this one:     DEFINITION Given  $x\in \Bbb R$, the integer part of $x$ is the unique $z\in \Bbb Z$ such that $$z\leq x &lt; z+1$$ and we denote it by $[x]$.   Now he asks to prove some basic things about it, such as: if $n\in \Bbb Z$, then $[x+n]=[x]+n$  So I proved it like this: Let $z=[x+n]$ and $z'=[x]$. Then we have that  $$z\leq x+n&lt;z+1$$  $$z'\leq x&lt;z'+1$$  Then $$z'+n\leq x+n&lt;z'+n+1$$  But since $z'$ is an integer, so is $z'+n$. Since $z$ is unique, it must be that $z'+n=z$.  However, this doesn't seem to get me anywhere to prove that  $$\left[ {2x} \right] = \left[ x \right] + \left[ {x + \frac{1}{2}} \right]$$  in and in general that   $$\left[ {nx} \right] = \sum\limits_{k = 0}^{n - 1} {\left[ {x + \frac{k}{n}} \right]} $$  Obviously one could do an informal proof thinking about "the carries", but that's not the idea, let alone how tedious it would be. Maybe there is some easier or clearer characterization of $[x]$ in terms of $x$ to work this out.  Another property is $$[-x]=\begin{cases}-[x]\text{ ; if }x\in \Bbb Z \cr-[x]-1 \text{ ; otherwise}\end{cases}$$  I argue: if $x\in\Bbb Z$, it is clear $[x]=x$. Then $-[x]=-x$, and $-[x]\in \Bbb Z$ so $[-[x]]=-[x]=[-x]$. For the other, I guess one could say:  $$n \leqslant x &lt; n + 1 \Rightarrow  - n - 1 &lt; x \leqslant -n$$  and since $x$ is not an integer, this should be the same as $$ - n - 1 \leqslant -x &lt; -n$$  $$ - n - 1 \leqslant -x &lt; (-n-1)+1$$  So $[-x]=-[x]-1$ Suppose $f$ and $g$ are Lebesgue measurable, we want to show $f+g$ is measurable. So, the hint is to consider the continuous functions $F : \mathbb{R}^2 \to \mathbb{R} $ given by $h(x) = F(f ,g ) $. If we can show $F$ Is measurable, then Taking $F = f +g $ would solve our problem.  In other words, I want to show that the set $R = \{ (f,g) : F(f,g) &gt; a $ } is lebesgue measurable.. But this set is just a rectangle in the plane. And since $F$ is continuous, then $R$ must be open, and hence a union of open rectangles which are measurable and hence $R$ must be measurable. Is this a correct approach to the problem? Can someone help me to make this formal? thanks how to extend a basis Can you use an external 301 redirect for a blog post hosted on wordpress.com? Mysterious! Beamer itemize has no bullets after adding a few packages this is my first time using beamer.  I copied a template from the sharelatex page on Beamer  Which works, and \begin{itemize} shows bullets     But after adding a few more packages that I need, all the bullets are gone!    What is going on and how can I fix this?  \documentclass{beamer}  \usepackage[utf8]{inputenc}    \usepackage{amsmath}  \usepackage{amsthm}     %Theorem Environment  \usepackage{amssymb}  \usepackage{multirow}  \usepackage{cancel}  \usepackage{amsfonts}  \usepackage{graphicx}  \usepackage{subfigure}  \usepackage{upgreek}     \usepackage{mathtools}  \usepackage{thmtools}  \usepackage{enumitem}       %Information to be included in the title page: \title{Sample title} \author{Anonymous} \institute{ShareLaTeX} \date{2014}  \begin{document}    \frame{\titlepage}    \begin{frame}  \frametitle{Sample frame title}  \begin{itemize} \item  This is a text in first frame.  \item This is a text in first frame. \item This is a text in first frame.  \end{itemize}  \end{frame}  \end{document} Does the universe have a center? If the big bang was the birth of everything, and the big bang was an event in the sense that it had a location and a time (time 0), wouldn't that mean that our universe has a center?  Where was the big bang? What is there now? Are we moving away from the center still? Are these even valid questions? What's the quickest Schengen consulate to issue a visa in London? VirtualBox 5.0.40 crashes the whole host since update to kernel 4.13.0-26-generic I received the updates through normal Software Updater, 10-Jan-2018. After this VirtualBox would not start any VM, complaining about dkms and asking to make modprobe vboxdrv. Following the advice I reinstalled virtualbox-dkms with:  sudo apt-get --reinstall install virtualbox-dkms   After this and a reboot I tried to start a VM which freezed the whole machine and a hard reboot was necessary.  Is there a way to make VirtualBox work with the latest kernels?  EDIT:  As suggested by N0rbert, the command:  apt-cache policy `dpkg -S VirtualBox | head -n1 | sed -e 's/://g' | awk '{print $1}'`  gives:   virtualbox-qt:   Installed: 5.0.40-dfsg-0ubuntu1.16.04.2   Candidate: 5.0.40-dfsg-0ubuntu1.16.04.2   Version table:  *** 5.0.40-dfsg-0ubuntu1.16.04.2 500         500 http://fr.archive.ubuntu.com/ubuntu xenial-updates/multiverse amd64 Packages         100 /var/lib/dpkg/status      5.0.18-dfsg-2build1 500         500 http://fr.archive.ubuntu.com/ubuntu xenial/multiverse amd64 Packages   EDIT (on 29-Mar-2018): Issue is resolved for me, with the Ubuntu Ubdate from today. I have seen that it had some virtualbox-updates, therefore I tried to boot with the most recent kernel again. Then I had to run  sudo apt-get --reinstall install virtualbox-dkms  And after this my virtual machines in VirtualBox started working without crashing the whole computer. Finally! Remove "Set as desktop background" from Windows context menu When I right click an image file in Windows, one of the context menu options is "Set as desktop background". I know some entries can be , so I'd like to know if it's possible to remove the "Set as background" option.  Note that while  can be found under HKEY_CLASSES_ROOT\, the "set as background" option seems to be located somewhere else. How can I reinstall GRUB to the EFI partition? I get different lightning render with the same scene camera setup.  Cycles render (both experimental and supported feature set) gets weaker lightning and needs more energy.  How can I get the same lightning and reflection setup with EEVEE and Cycles? How do I calculate the closest power of 2 or 10 a number is? What is the most efficient way to cacluate the closest power of a 2 or 10 to another number? e.g.  3.5 would return 4 for power of 2 and 1 for power of 10  123 would return 128 for power of 2 and 100 for power of 10  0.24 would return 0.25 for power of 2 and 0.1 for power of 10  I'm just looking for the algorithm and don't mind the language. Are there attacks that break collision resistance but not preimage resistance?