# \donttest{
library(morphomap)
data(HomFem38023)
meshes<-morphomapSegm(HomFem38023, param1=4)
perMesh<-meshes$external
endMesh<-meshes$internal
mech_length<-380.23
rawSections<-morphomapCore(out.sur=perMesh, inn.sur=endMesh, num.sect=61 ,
mech.len = mech_length, start = 0.2,end=0.8,num.points = 500)
# Shape coordinates defining as center the barycenter of the cortical area
shapeSections_CCA<-morphomapShape(rawSections,21,sects_vector=NULL, cent.out="CCA",
delta=0.1,side="left")
# First the first cross section (2D)
morphomapPlotShape(shapeSections_CCA,dims=2,cent.out="CCA",vecs=1)
# First the first cross section (3D)
morphomapPlotShape(shapeSections_CCA,dims=3,size=0.5,lwd=2,cent.out="I",vecs=1)
# The entire diaphysis (3D)
morphomapPlotShape(shapeSections_CCA,dims=3,size=0.5,lwd=2,cent.out="I",vecs=NULL)
# Shape coordinates defining as center the barycenter of the external perimeter
shapeSections_E<-morphomapShape(rawSections, 21, sects_vector=NULL, cent.out="E",
delta=0.1, side="left")
# First the first cross section (2D)
morphomapPlotShape(shapeSections_E,dims=2,cent.out="E",vecs=1)
# First the first cross section (3D)
morphomapPlotShape(shapeSections_E,dims=3,size=0.5,lwd=2,cent.out="I",vecs=1)
# The entire diaphysis (3D)
morphomapPlotShape(shapeSections_E,dims=3,size=0.5,lwd=2,cent.out="I",vecs=NULL)
# Shape coordinates defining as center the barycenter of the internal perimeter
shapeSections_I<-morphomapShape(rawSections, 21, sects_vector=NULL, cent.out="I",
delta=0.1, side="left")
# First the first cross section (2D)
morphomapPlotShape(shapeSections_I,dims=2,lines=TRUE,cent.out="I",vecs=1)
# First the first cross section (3D)
morphomapPlotShape(shapeSections_I,dims=3,lines=TRUE,centroid=TRUE, size=0.5,
lwd=2,cent.out="I",vecs=1)
# The entire diaphysis (3D)
morphomapPlotShape(shapeSections_I,dims=3,size=0.5,lwd=2,cent.out="I",vecs=NULL)
# }
Run the code above in your browser using DataLab