Hi everyone, I'm doing a task in which I have to do cross-tab and pairwise correlations for 3 dummy variables respect to some socio-demographic variables. I'm using this command:
clear matrix
capture close
capture log close
set matsize 800
set more off
g self_assesment_dummy = 1 if (d22<=6)
replace self_assesment_dummy = 0 if self_assesment_dummy==.
*svy: tab self_assesment_dummy if target<5, ci percent

g donotknow_dummy = 1 if (d22==97)
replace donotknow_dummy = 0 if donotknow_dummy==.
*svy: tab self_assesment_dummy if target<5, ci percent

g refusal_dummy = 1 if (d22==99)
replace refusal_dummy = 0 if refusal_dummy==.

putexcel set Test1
putexcel set Test1, sheet("corrd22") replace

global socio_demographics "(a total of 20 variables)"

global SelfAssesment "self_assesment_dummy donotknow_dummy refusal_dummy "

foreach var of varlist $SelfAssesment {
foreach x of varlist $socio_demographics {
corr_svy `var' `x' [pweight=weight], sig star (0.01)
corr_svy `var' `x' [pweight=weight], sig star (0.05)
corr_svy `var' `x' [pweight=weight], sig star (0.10)

}
}

The question is: how can I report on excel all the values of the correlations in a table? (copy and past is really hard because there is a huge number of matrix generated)

Thanks in advance!