The function in the R survival package to get the baseline hazard rate is basehaz
.
Then you need to multiply it for the various $e^{\beta}$ to get the specific hazard rate given the coefficients you have found.
A simple example may help:
library(survival) #survival analysis
library(eha) #used for data
data(oldmort) #create the data
# Create surv data set
mort <- Surv(time=oldmort$enter,time2=oldmort$exit,event=oldmort$event)
reg_fit <- coxph(formula=mort~oldmort$sex)
summary(reg_fit)
# Now get baseline curve
baseline <- basehaz(reg_fit)
# Draw baseline hazard (that's male)
plot(baseline$time, baseline$hazard, type='l',main="Hazard rates")
# Draw female hazard
lines(baseline$time, exp(-0.1929)*baseline$hazard, col="blue")
the $\exp(-0.1929)=0.8245$ is copied and pasted from the summary results of cox regression, summary(reg_fit)
, implying that the females in the data have hazard rates $18\%$ lower than the males.