문제

우리가 사용하여 그 결과에 대한 데이터를 분석의 모든 우리의 기관에 제공됩니다.고 싶 어떻게든 보고서를 만들고 데이터의 분석을 위해 자동으로 이러한 월별 보고합니다.보고서 요약 테이블이 포함되어 있의 보고 지표의 부부는 그래픽스의 핵심 지표,그리고 분석은 테이블을 보여주는 통계적으로 유의한 차이는 데이터 그룹이 있습니다.나는 다음과 같이 될 pdf 고 자동으로 이메일로 전송하는 기관입니다.어떤 아이디어에서 소프트웨어를 사용할 수 있는 자동화하는 이?

도움이 되었습니까?

해결책

때문에 당신이 사용하는 오페라 하우스 그리고 프리덤 트레일을 분석할 수 있습을 할 수 있도록 무거운 짐 보고서의 자동화뿐만 아니라.

트릭를 사용하고 오페라 하우스 그리고 프리덤 트레일 패키지는 다음과 같-rtfutil-수출하는 테이블과 그래픽을 설명 하나의 문서입니다.그 시점에서 필요로 변환하는 것을 pdf 이메일을 보내기 전에습니다.

여기에는 일부에 대한 샘플 코드를 사용하여-rtfutil-자동 생성한 문서의 표를 포함하여 두 그래픽(플러스 일부 단락의 텍스트)에 RTF 문서(시스템을 사용하여 데이터 집합"은 자동입니다.dta"예를 들어):

    ******

    clear

    //RTF UTILITY FOR INSERTING GRAPHICS & TABLES//

    local sf "/users/ppri/desktop/"

            //SETUP
             sysuse auto, clear
             twoway scatter mpg price,  mlabel(make) || lfitci mpg price
             graph export "`sf'myplot1.eps", replace
             twoway scatter price mpg,  mlabel(make) by(for)
             graph export "`sf'myplot2.eps", replace

             **
             tempname handle1

            //RTFUTIL
             rtfopen `handle1' using "`sf'mydoc1.rtf", replace
             file write `handle1' _n  _tab  "{\pard\b SAMPLE DOCUMENT \par}" _tab  _n 
             file write `handle1' _n "{\line}" 
             // Figure1
             file write `handle1' "{\pard\b FIGURE 1:  Plot of Price\par}" _n
             rtflink `handle1' using "`sf'myplot1.eps"
             // Figure2
             file write `handle1' _n "{\page}" _n /*
*/ "{\pard Here is the plot and a paragraph about it.  Here is the plot and a paragraph about it.  Here is the plot and a paragraph about it.  Here is the plot and a paragraph about it.....blah blah blah  blah blah   \line}" _n
             file write `handle1' _n "{\line}" 
             file write `handle1' "{\pard\b FIGURE2:  Plots of Price vs. MPG\par}" _n
             rtflink `handle1' using "`sf'myplot2.eps"
             //  Table Title
             file write `handle1' _n "{\page}" _n
             file write `handle1' _n "{\par\pard}" _n /*
*/   "{\par\pard  HERE IS A TABLE WITH THE CARS:  \par\pard}" _n
             file write `handle1' _n "{\par\pard}" _n


             // Summary Table
                      rtfrstyle make mpg weight, cwidths(2000 1440 1440) local(b d e)
                      listtex make foreign mpg if mpg<15, /*
                */   handle(`handle1') begin("`b'") delim("`d'") end("`e'") /*
                */  head("`b'\ql{\i Make}`d'\qr{\i Foreign}`d'\qr{\i MPG }`e'")
                      file write `handle1' _n "{\line}"  
                      file write `handle1' _n _tab(2)  /*
               */ "{\pard\b Sources:  Census Data, etc...  \par}" _n _n
                    **
             rtfclose `handle1'

    ******

이 모든 요소에 대해 물었으로 RTF 문서(주의해야 어떤 문제로의 포장 이 코드는 복사/붙여 웹 페이지에서).
귀하의 질문에,당신은 또한 언급하고자 PDF 파일을 생성하는 중에 이 프로세스.여기에 당신이 갈 필요가 일부를 사용하 non-Stata 솔루션입니다.를 사용하는 경우 Mac OSX 사용할 수 있는 터미널 변환기-유틸리티 또는 자동화 이렇게 하고,또는 여기에서 다른 솔루션: http://codesnippets.joyent.com/posts/show/1601
나는 사용하지 않는 윈도우 그래서 나는 확실하지 않에 대한 솔루션과 OS.행운을 빕니다.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top