We consider an analytic function-germ $f{:}\,(\mathbb{R}^n,0) \rightarrow (\mathbb{R},0)$ with an isolated critical point at $0$. For a sufficiently small ball $B_\varepsilon$ of radius $\varepsilon$ and a sufficiently small regular value $\delta$ of $f$, we give degree formulas for the following Euler–Poincaré characteristics: $$\chi( f^{-1}(\delta) \cap B_\varepsilon \cap \{(-1)^{\epsilon_1} x_1\ge 0,\ldots, (-1)^{\epsilon_k} x_k \ge 0\}),$$ where $k \in \{1,\ldots,n\}$ and $\epsilon_i \in \{0,1\}$. This leads to degree formulas for $$ \chi (\{f * 0\} \cap S_\varepsilon \cap \{(-1)^{\epsilon_1} x_1\ge 0,\ldots, (-1)^{\epsilon_k} x_k \ge 0\}),$$ where $* \in \{\le,=,\ge\}$. Combining this with the Eisenbud–Levine–Khimshiashvili's formula, we obtain signature formulas for $$\chi( W \cap\{(-1)^{\epsilon_1} x_1\ge 0,\ldots, (-1)^{\epsilon_k} x_k \ge 0\}),$$ where $W$ is either the link of a weighted-homogeneous singularity or any compact algebraic set of $\mathbb{R}^n$.